8000 Add support to configs via environment variables · Issue #45 · edgurgel/poxa · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Add support to configs via environment variables #45
Closed
@RobertoSchneiders

Description

@RobertoSchneiders

To use the docker image, I have to create a config file and copy it to the container (like this). It would be easier (maybe better) to configure this settings by environment variables.

I'm deploying to AWS Elastic Beanstalk and If it were possible to configure by environment variables I will be able to get the app up and running just by configuring the env vars on AWS Console and creating a file like this:

Dockerrun.aws.json

{
  "AWSEBDockerrunVersion": "1",
  "Image": {
    "Name": "edgurgel/poxa",
    "Update": "true"
  },
  "Ports": [
    {
      "ContainerPort": "8080"
    }
  ],
  "Logging": "/var/log/nginx"
}

I'm new to Elixir, so, I'm not familiar with Mix. From what I understand, the config.exs file is already getting some configs from env vars, but, this code is executed only on docker image generation command is executed (MIX_ENV=prod mix edip --prefix edgurgel) and not on the application initialization. So, it doesn't help who is trying to use the docker image. Right?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0