Skip to content

uwsgi::app should support setting multiple environment variables #1

@jarshwah

Description

@jarshwah

There is currently no way to support setting multiple environment variables for a single application.

uwsgi::app:
  django:
    application_options:
      env: 'ORACLE_HOME=/path/to/oracle'

Since the module writes out the template with key = option we have to put the entire ``VAR=VAL` on the right hand side, to prevent spaces between the env var. We should support another option called environment_variables that accepts a hash of key=value.

It'd look like this:

uwsgi::app:
  django:
    application_options:
      env: 'ORACLE_HOME=/path/to/oracle'
    environment_variables:
      ORACLE_HOME: '/path/to/oracle'
      DJANGO_SETTINGS_MODULE: 'myproject.settings'

I don't have this problem right yet since I'm only using a single environment variable, but if anyone else runs into this as being a problem let me know and I'll push out a fix pretty quickly.

PR welcome also =)

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions