Skip to content

Commit

Permalink
[186333897]: don't copy whole repo into base image
Browse files Browse the repository at this point in the history
  • Loading branch information
gergness committed Nov 1, 2023
1 parent a228376 commit ce0b5d3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions docker/jenkins/Dockerfile.rcrunch
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,16 @@ ARG HOMEDIR=/home/jenkins
ARG USER=997
ARG GROUP=991
ENV HOMEDIR=${HOMEDIR}
ENV R_LIBS=${HOMEDIR}/R/master
ENV R_LIBS=${HOMEDIR}/rlibs
USER root
RUN locale-gen en_US.UTF-8
ENV LANG=en_US.UTF-8
RUN apt-get update && apt-get install build-essential libtiff5-dev libfribidi-dev libfontconfig1-dev libgit2-dev libssl-dev libcurl4-gnutls-dev libxml2-dev libsodium-dev -y
# Add the user/group jenkins
RUN groupadd --gid ${GROUP} jenkins \
&& useradd --uid ${USER} --gid jenkins --shell /bin/bash --create-home -d ${HOMEDIR} jenkins
COPY --chown=jenkins:jenkins . ${HOMEDIR}
# Copy only the minimal amount of the package to install dependencies
COPY --chown=jenkins:jenkins ./DESCRIPTION ./Makefile ${HOMEDIR}
WORKDIR ${HOMEDIR}
RUN echo 'local({\n\
r <- getOption("repos")\n\
Expand Down

0 comments on commit ce0b5d3

Please sign in to comment.