To cache the layer containing the dependencies from your Clojure project, you can execute a command without starting a REPL. This downloads all common dependencies, which are then be cached.
For example:
FROM clojure:openjdk-14-tools-deps-alpine
# Cache and install Clojure dependencies
COPY deps.edn .