Add docker image size limit #96
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.
This just adds an option to limit the size of the build docker images. This looks at the final docker image size after all dependencies etc are included. This means that it will overestimate the actual disk space used since it overcounts shared images.
E.g. if there are two teams each using the 5GB (made up numbers) big python image as their base and then include 1 GB of their own code in both their generators and solvers we would consider each image to be 6GB big, even though only 9GB of disk space are used by docker in total.
I don't think there is a good way to track the actual size of the image on disk, but I think tracking it like this also is the most fair since it won't lead to discrepancies based on what images already happen to be installed or what team was the first to use a particular base.