Combine tools.deps and Leiningen images #229
Draft
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 is my take on #224. There are a lot of changes, so we might as well start the review and discuss the details early.
Summary:
leinandclj/clojure, respectively).dockerfile.leinanddockerfile.tools-depsnamespaces still exist and serve as building blocks for the newdockerfile.combinednamespace. Thecombinednamespace assembles the parts from Leiningen and tools.deps to install both in one RUN/layer. The number of overall layers in the resulting images is minimized.leinandtools-depsimages is their ENTRYPOINT.leinimages continue to haveleinas their entrypoint,tools-depscontinue to haveclj.tools-depsremain a "default" build tool, meaning that tags without build tool specified will havecljentrypoint.curl.wgetis no longer needed, so we don't install or purge it.latesttag no longer requires a separate docker build context, and now points to the image with default JDK, distro, and build tool (temurin-21-tools-deps-bookwormto be exact).temurin-17,temurin-22, etc.). I don't know if not having those was intentional or an oversight. If it's the former, I can remove that.cfg/build-tools(previously:installer-hashes) a dynamic variable, because it had to be dragged 5-6 levels through the call stack to the single place where it is actually needed.Will be happy to iterate on the PR now or let it sit until the decision on #224 is made.