Skip to content

Commit

Permalink
(maint) configure lein local-repo for easy caching
Browse files Browse the repository at this point in the history
  • Loading branch information
h0tw1r3 committed Apr 27, 2024
1 parent c543cc6 commit b19d0fa
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,8 @@ This container assumes that the code you're building will be in `/workspace`. Th
will be copied into `/output` before the container terminates, and if you're building a
custom ezbake that will be cloned into `/ezbake`.

Lein is configured to use `/repo` as it's local-repo. Volume map to cache dependencies between builds.

1. Run from a remotely accessible repo (github, gitlab, etc)

This is by far the fastest build option, but does require the extra step of committing and pushing your code
Expand Down
5 changes: 5 additions & 0 deletions docker/ezbake/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,11 @@ RUN gem install --no-doc bundler fpm && \
COPY docker/ezbake/docker-entrypoint.sh /
RUN chmod +x /docker-entrypoint.sh

# setup lein for easy caching
RUN mkdir /repo && \
mkdir /root/.lein && \
echo "{:user {:local-repo "/repo"}}" > /root/.lein/profiles.clj

# Have the latest ezbake installed
COPY . /ezbake_src
WORKDIR /ezbake_src
Expand Down

0 comments on commit b19d0fa

Please sign in to comment.