leiningen

vemv 2022-09-14T11:39:47.617589Z

can i create a local .m2 dir after running lein install? Its contents being derived from that command so that I can copy it for Docker purposes

2022-09-16T08:41:51.544709Z

Plus 1 for jib! We use it in basically all our deployed java / clojure applications. The caching works very good with Github Actions and builds are neat!

eskos 2022-09-15T10:16:16.488019Z

You probably want something like https://github.com/vehvis/lein-jib-build

πŸ‘πŸ» 1
eskos 2022-09-15T10:17:11.644939Z

(other libraries based on jib are available as well) https://github.com/GoogleContainerTools/jib does the sensible thing of putting dependencies into its own layer and app to another; read a bit about it, it’s actually really well thought out

Rupert (Sevva/All Street) 2022-09-14T15:07:03.299699Z

A few options that I have used in the past 1. I used to use a lein plugin for this in the past. https://github.com/djpowell/lein-libdir it generates a directory of all the depenendency jars. 2. Another option that you have is to generate an uberjar (lein uberjar) then you don't have to worry about dependency jars at all. 3. Setup remote maven repo server and push your dependencies there. Do you intend to copy your jars into a docker image?

Rupert (Sevva/All Street) 2022-09-14T15:13:30.691159Z

Seems that m2 location can be overriden with an environment variable

export MAVEN_OPTS="-Dmaven.repo.local=/path/to/repository"
Not tested by me though.

vemv 2022-09-14T15:19:11.611639Z

thanks much! I'm having luck with the :local-repo ".m2" option so far

πŸ‘ 3
2022-09-14T17:41:30.122759Z

I've used the :local-repo option for things like this