WIP - Proposal for allowing envfile to be defined in docker-compose.yml file#8322
Closed
jonmchan wants to merge 1 commit intodocker:masterfrom
Closed
WIP - Proposal for allowing envfile to be defined in docker-compose.yml file#8322jonmchan wants to merge 1 commit intodocker:masterfrom
jonmchan wants to merge 1 commit intodocker:masterfrom
Conversation
Contributor
|
Thanks for taking the time to create this issue/pull request! Unfortunately, Docker Compose V1 has reached end-of-life and we are not accepting any more changes (except for security issues). Please try and reproduce your issue with Compose V2 or rewrite your pull request to be based on the v2 branch and create a new issue or PR with the relevant Compose V2 information. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR does not meet coding standards. Looking for someone to take this up and add tests and documentation. I'm not familiar enough with python or this project to do this.
This is my proposal for resolving #6741. It allows the
.envfile to be defined from docker-compose.yml file allowing for it to be remapped to.env.dockeror/dev/nullto not conflict with applications that utilize the.envfile.This implementation evaluates the
docker-compose.ymlfile an extra time, looking forx-env-file. If this is accepted as a solution, aenv-fileoption should be added to the docker-compose schema/spec. I could not find an appropriate section to add a config option like this in the current spec.This solution preserves the ability to utilize
--env-filecommand line option to override thex-env-filedirective in thedocker-compose.ymlfile.Appreciate any feedback. Thank you.
Resolves #6741