Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
S
science-docker
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Rafal Skolasinski
science-docker
Commits
741824fa
Commit
741824fa
authored
5 years ago
by
Rafal Skolasinski
Browse files
Options
Downloads
Patches
Plain Diff
decrease image built time by switching back to NB_USER earlier
parent
223456a2
No related branches found
No related tags found
No related merge requests found
Pipeline
#19172
passed
5 years ago
Stage: mirror
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
science/Dockerfile
+11
-12
11 additions, 12 deletions
science/Dockerfile
with
11 additions
and
12 deletions
science/Dockerfile
+
11
−
12
View file @
741824fa
...
...
@@ -7,14 +7,18 @@ USER root
# add ssh-client to provide ssh-agent and ssh-add commands
RUN
apt-get update
&&
apt-get
install
--yes
openssh-client
# Switch back to jovyan to avoid accidental container runs as root
USER
$NB_UID
# Add environment file
RUN
mkdir
/environments
COPY
environment.yml /environments/
COPY
environment.yml /tmp/
# Create the main research environment
RUN
conda
env
update
-n
base
-f
/
environments
/environment.yml
&&
\
RUN
conda
env
update
-n
base
-f
/
tmp
/environment.yml
&&
\
pip
install
xyzpy
==
0.3.1
tqdm
==
4.32.2
&&
\
conda clean
-tipsy
conda clean
-tipsy
&&
\
fix-permissions
$CONDA_DIR
&&
\
fix-permissions /home/
$NB_USER
# Enable jupyter extension
ARG
NODE_OPTIONS=--max-old-space-size=4096
...
...
@@ -26,11 +30,6 @@ RUN jupyter labextension install nbdime-jupyterlab && \
jupyter labextension
install
jupyterlab-chart-editor@1.1
--no-build
&&
\
jupyter lab build
&&
\
jupyter nbextension
enable
--py
widgetsnbextension
--sys-prefix
&&
\
jupyter nbextension
enable
--py
plotlywidget
--sys-prefix
# Fix permissions (required when following the base image)
RUN
fix-permissions
$HOME
&&
\
fix-permissions
$CONDA_DIR
# Switch back to jovyan to avoid accidental container runs as root
USER
$NB_UID
jupyter nbextension
enable
--py
plotlywidget
--sys-prefix
&&
\
fix-permissions
$CONDA_DIR
&&
\
fix-permissions /home/
$NB_USER
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment