derek-thomas HF staff commited on
Commit
9d5e854
1 Parent(s): bc5faf6

Trying to copy the best way

Browse files
Files changed (1) hide show
  1. Dockerfile +3 -7
Dockerfile CHANGED
@@ -53,6 +53,9 @@ RUN curl -sLo ~/miniconda.sh https://repo.continuum.io/miniconda/Miniconda3-py39
53
 
54
  WORKDIR $HOME/app
55
 
 
 
 
56
  #######################################
57
  # Start root user section
58
  #######################################
@@ -60,10 +63,6 @@ WORKDIR $HOME/app
60
  USER root
61
 
62
  # User Debian packages
63
- COPY ./jupyterlab/ /root/
64
- #COPY ./jupyterlab/packages.txt packages.txt
65
- #COPY ./jupyterlab/on_startup.sh on_startup.sh
66
-
67
  ## Security warning : Potential user code executed as root (build time)
68
  RUN --mount=target=/root/packages.txt,source=/root/packages.txt \
69
  apt-get update && \
@@ -85,9 +84,6 @@ USER user
85
  RUN --mount=target=requirements.txt,source=requirements.txt \
86
  pip install --no-cache-dir --upgrade -r requirements.txt
87
 
88
- # Copy the current directory contents into the container at $HOME/app setting the owner to the user
89
- COPY --chown=user ./jupyterlab/ $HOME/app
90
-
91
  RUN chmod +x start_server.sh
92
 
93
  COPY --chown=user ./jupyterlab/login.html /home/user/miniconda/lib/python3.9/site-packages/jupyter_server/templates/login.html
 
53
 
54
  WORKDIR $HOME/app
55
 
56
+ # Copy the current directory contents into the container at $HOME/app setting the owner to the user
57
+ COPY --chown=user ./jupyterlab/ $HOME/app
58
+
59
  #######################################
60
  # Start root user section
61
  #######################################
 
63
  USER root
64
 
65
  # User Debian packages
 
 
 
 
66
  ## Security warning : Potential user code executed as root (build time)
67
  RUN --mount=target=/root/packages.txt,source=/root/packages.txt \
68
  apt-get update && \
 
84
  RUN --mount=target=requirements.txt,source=requirements.txt \
85
  pip install --no-cache-dir --upgrade -r requirements.txt
86
 
 
 
 
87
  RUN chmod +x start_server.sh
88
 
89
  COPY --chown=user ./jupyterlab/login.html /home/user/miniconda/lib/python3.9/site-packages/jupyter_server/templates/login.html