@@ -28,7 +28,7 @@ RUN apt-get update \
2828
2929# # install julia
3030RUN mkdir /opt/julia \
31- && curl -L https://julialang-s3.julialang.org/bin/linux/x64/1.4/julia-1.4.0 -linux-x86_64.tar.gz | tar zxf - -C /opt/julia --strip=1 \
31+ && curl -L https://julialang-s3.julialang.org/bin/linux/x64/1.4/julia-1.4.1 -linux-x86_64.tar.gz | tar zxf - -C /opt/julia --strip=1 \
3232 && chown -R 1000 /opt/julia \
3333 && ln -s /opt/julia/bin/julia /usr/local/bin
3434
@@ -85,22 +85,32 @@ ARG JULIA_FFTW_PROVIDER=MKL
8585# Project.toml (and making a dummy src/CMBLensing.jl which we have to), so that
8686# other changes to files in src/ won't have to redo these steps
8787COPY --chown=1000 Project.toml $HOME/CMBLensing/
88- COPY --chown=1000 docs/Project.toml $HOME/CMBLensing/docs/
88+ COPY --chown=1000 docs/Project.toml docs/Manifest.toml $HOME/CMBLensing/docs/
8989RUN mkdir $HOME/CMBLensing/src && touch $HOME/CMBLensing/src/CMBLensing.jl
9090ENV JULIA_PROJECT=$HOME/CMBLensing/docs
91- RUN julia -e 'using Pkg; pkg"dev ~/CMBLensing; instantiate; add ProgressMeter#master; precompile"' \
91+ ENV CMBLENSING_NONLAZY_PYPLOT=1
92+ RUN julia -e 'using Pkg; pkg"instantiate"' \
93+ && if [ "$PRECOMPILE" = "1" ]; then julia -e 'using Pkg; pkg"precompile"' ; fi \
9294 && rm -rf $HOME/.julia/conda/3/pkgs
9395COPY --chown=1000 src $HOME/CMBLensing/src
94- RUN (test $PRECOMPILE = 0 || julia -e 'using Pkg; pkg"precompile"' )
96+ RUN if [ " $PRECOMPILE" = "1" ]; then julia -e 'using Pkg; pkg"precompile"' ; fi
9597
9698
9799
98100# # PackageCompiler
99101# bake CMBLensing into the system image to further speed up load times and
100102# reduce memory usage during package load (the latter is necessary otherwise we
101103# hit the mybinder memory limit)
102- RUN test $PACKAGECOMPILE = 0 \
103- || julia -e 'using PackageCompiler; create_sysimage([:CMBLensing],cpu_target="generic",replace_default=true)'
104+ COPY docs/pyplot_packagecompiler_script.jl /tmp/
105+ RUN if [ "$PACKAGECOMPILE" = "1" ]; then \
106+ julia -e 'using PackageCompiler; \
107+ create_sysimage(\
108+ [:PyCall, :IJulia, :PyPlot, :CMBLensing], \
109+ cpu_target="generic", \
110+ replace_default=true, \
111+ script="/tmp/pyplot_packagecompiler_script.jl" \
112+ )' ; \
113+ fi
104114
105115# # execute documentation notebooks and save outputs
106116COPY --chown=1000 docs/src $HOME/CMBLensing/docs/src
0 commit comments