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:
lein
andclj/clojure
, respectively).dockerfile.lein
anddockerfile.tools-deps
namespaces still exist and serve as building blocks for the newdockerfile.combined
namespace. Thecombined
namespace 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.lein
andtools-deps
images is their ENTRYPOINT.lein
images continue to havelein
as their entrypoint,tools-deps
continue to haveclj
.tools-deps
remain a "default" build tool, meaning that tags without build tool specified will haveclj
entrypoint.curl
.wget
is no longer needed, so we don't install or purge it.latest
tag 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-bookworm
to 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.