Description
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?