Simplify docker-compose logic #12
Open
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.
The original docker-compose instructions are rather hard to modify: there are large amounts of duplication, subtle differences between e.g. dev vs non-dev defaults, and few instructions on how to persist customizations across multiple build targets.
This PR leverages docker include, profile and extend to significantly reduce code duplication and make build processes more intuitive.
New logic consolidates all common configurations into
docker-compose-helpers.yml, whose individual services are included in the maindocker-compose.ymlwith slight customizations. The biggest breaking change is the lack of specific.build.ymland.gpu.ymlfiles, since this is now achieved withdocker-compose buildanddocker-compose build --profile ia-gpu(oria-cpu).TODO:
@SixK do you have insight on the above todos? I'd love your feedback especially on getting the (untested)
ia-cpuportion vs. gpu properly split