This commit is contained in:
@@ -5,6 +5,7 @@
|
|||||||
.gitignore
|
.gitignore
|
||||||
|
|
||||||
renv/library
|
renv/library
|
||||||
|
renv/cache
|
||||||
renv/staging
|
renv/staging
|
||||||
|
|
||||||
*.Rproj
|
*.Rproj
|
||||||
@@ -10,6 +10,7 @@
|
|||||||
|
|
||||||
# renv local library/state (keep renv.lock and renv/activate.R tracked)
|
# renv local library/state (keep renv.lock and renv/activate.R tracked)
|
||||||
renv/library/
|
renv/library/
|
||||||
|
renv/cache/
|
||||||
renv/python/
|
renv/python/
|
||||||
renv/staging/
|
renv/staging/
|
||||||
|
|
||||||
|
|||||||
+2
-4
@@ -27,7 +27,7 @@ COPY .Rprofile /srv/shiny-server/.Rprofile
|
|||||||
# Prevent renv attempting to use pak
|
# Prevent renv attempting to use pak
|
||||||
ENV RENV_CONFIG_PAK_ENABLED=FALSE
|
ENV RENV_CONFIG_PAK_ENABLED=FALSE
|
||||||
ENV RENV_DOWNLOAD_METHOD=libcurl
|
ENV RENV_DOWNLOAD_METHOD=libcurl
|
||||||
ENV RENV_PATHS_CACHE=/opt/renv/cache
|
ENV RENV_PATHS_CACHE=/srv/shiny-server/renv/cache
|
||||||
|
|
||||||
# Some CRAN packages in this lockfile fail under Ubuntu hardening defaults
|
# Some CRAN packages in this lockfile fail under Ubuntu hardening defaults
|
||||||
# because -Werror=format-security turns benign warnings into build failures.
|
# because -Werror=format-security turns benign warnings into build failures.
|
||||||
@@ -38,9 +38,7 @@ RUN for f in /usr/local/lib/R/etc/Makeconf /usr/lib/R/etc/Makeconf; do \
|
|||||||
done
|
done
|
||||||
|
|
||||||
# Install renv and restore project packages
|
# Install renv and restore project packages
|
||||||
RUN --mount=type=cache,target=/opt/renv/cache \
|
RUN R --vanilla -e "install.packages('renv', repos='https://cran.rstudio.com')" && \
|
||||||
--mount=type=cache,target=/root/.cache/R/renv \
|
|
||||||
R --vanilla -e "install.packages('renv', repos='https://cran.rstudio.com')" && \
|
|
||||||
R --vanilla -e "source('.Rprofile'); renv::restore(prompt=FALSE)"
|
R --vanilla -e "source('.Rprofile'); renv::restore(prompt=FALSE)"
|
||||||
|
|
||||||
# Copy the application after dependencies so regular code changes do not
|
# Copy the application after dependencies so regular code changes do not
|
||||||
|
|||||||
Reference in New Issue
Block a user