Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docker-compose build shouldn't complain about missing env file #3346

Closed
garyp opened this issue Apr 18, 2016 · 3 comments
Closed

docker-compose build shouldn't complain about missing env file #3346

garyp opened this issue Apr 18, 2016 · 3 comments

Comments

@garyp
Copy link

garyp commented Apr 18, 2016

Our docker-compose.yml file references an env_file that gets auto-generated by a script that we run before docker-compose up. Which means that the env file isn't available when we run docker-compose build. Since the build process doesn't use environment variables, this shouldn't be a problem. But docker-compose build exits with an error of "Couldn't find env file: /foo/bar/my.env".

Instead, docker-compose build should ignore the non-existent env file. It should only print the error if the env file isn't found by the time docker-compose up is run.

@dnephin
Copy link

dnephin commented Apr 18, 2016

Duplicate of #1973

@dnephin dnephin closed this as completed Apr 18, 2016
@alanjds
Copy link

alanjds commented Jul 5, 2017

Seems to me that this is not a duplicate. Separating the parse in 2 steps will not allow some env_file to be non-existent. On the phase that it is read, non-existing files will raise an error.

The asked here is to be ok and simple ignored when a non-existing file got tried. I would like a warning, anyway...

@alanjds
Copy link

alanjds commented Jul 5, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants