Add configurable COMPOSE_FILE to setup flow. #22299
Merged
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.
Relates to: AMOENG-599
Description
This PR adds COMPOSE_FILE to the .env setup flow for running the project. This allows users to configure how the project runs in a predictable way.
Context
You could already use COMPOSE_FILE (built in feature of docker compose) but our
make setup
flow doesn't consider this variable when managing the .env file and so it could be removed. adding it explicitly to the flow ensures a sensible default is maintained and that any user overrides are not erased unintentionally.Testing
This PR enables several new features locally.
This is the "default" behavior for CI preventing any host files in the runner from influencing the tests.
This will run the digest you pass and not mount local files. You can verify this by creatin a new file on the host, and checking it does NOT exist in the container.
Similarly to the above you can specify a COMPOSE_FILE environment variable either in the cli or in the .env file itself to specify additional compose files to add to your configuration. This is useful for those wanting to run
docker-compose.private.yml
@wagnerand CC please verify this works as expected.