beacon-biosignals / julia_pod

k8s native julia development
MIT License
10 stars 3 forks source link

preserve all #62

Closed kolia closed 1 year ago

kolia commented 1 year ago

When adding default Revise and PProf (which are totally arbitrary things to put into the base project environment...), add preserve=Pkg.PRESERVE_ALL kwarg per @ssfrr's suggestion.

kleinschmidt commented 1 year ago

sysimage.jl also does Pkg operations, is there a chance that it would also modify the manifest in the process?

kolia commented 1 year ago

sysimage.jl also does Pkg operations, is there a chance that it would also modify the manifest in the process?

sysimage.jl just calls create_sysimage; I assume that doesn't mess with versions but I could be wrong.

There are a couple of calls to Pkg.rm on lines 19 and 23 of Dockerfile.template, but inferring from the Pkg.jl docs seems like removing dependencies shouldn't change versions either.

So it seems likely to be just the adding of Revise and friends that can mess with versions, but I haven't done any experiments to check.

kleinschmidt commented 1 year ago

sysimage.jl calls Pkg.add here: https://github.com/beacon-biosignals/julia_pod/blob/ba16afc42d99881d3689ed20c83f0b22bb816b3f/add_me_to_your_PATH/sysimage.jl#L22

kleinschmidt commented 1 year ago

and it's run in the project environment at least if I'm understanding correctly: https://github.com/beacon-biosignals/julia_pod/blob/ba16afc42d99881d3689ed20c83f0b22bb816b3f/add_me_to_your_PATH/Dockerfile.template#L74-L75

ssfrr commented 1 year ago

yeah, agreed it should also be added to that line in sysimage.jl. It is indeed called in the project context

Otherwise LGTM.

kolia commented 1 year ago

sysimage.jl calls Pkg.add here:

https://github.com/beacon-biosignals/julia_pod/blob/ba16afc42d99881d3689ed20c83f0b22bb816b3f/add_me_to_your_PATH/sysimage.jl#L22

o right, missed that one ✅

kolia commented 1 year ago

In practice as soon as a julia-1.9 docker image is made available, we'll probably want to switch to that and gut the whole sysimage part out of julia_pod, which will simplify things a lot. In the mean time...