-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
38 lines (33 loc) · 998 Bytes
/
Dockerfile
File metadata and controls
38 lines (33 loc) · 998 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
ARG BASE_IMG
FROM $BASE_IMG
USER root
RUN apt update && apt install -y curl
RUN curl -fsSL https://deb.nodesource.com/setup_18.x | bash -
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y nodejs
RUN pip install --upgrade -v \
"datasets" \
"ipywidgets" \
"jupyter" \
"jupyterlab-git" \
"jupyterlab>=4.0.0" \
"matplotlib" \
"pip" \
"requests" \
"sentencepiece" \
"tensorboard" \
"tqdm==4.62.2" \
"transformers[torch]" \
&& rm -rf ~/.cache/pip/*
RUN apt update && apt install -y git
RUN if ! id jovyan >/dev/null 2>&1; then \
useradd -m -u 1000 -g 100 -s /bin/bash -d /home/jovyan jovyan; \
fi
RUN apt install -y sudo \
&& echo "jovyan ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers \
&& usermod -a -G root jovyan \
&& mkdir -p /home/jovyan/.local && mkdir -p /home/jovyan/.jupyter \
&& chown -R 1000:100 /home/jovyan/.local && chown -R 1000:100 /home/jovyan/.jupyter
ENV SHELL=/bin/bash
ENV JUPYTER_DATA_DIR=/home/jovyan/.local
USER jovyan
WORKDIR /home/jovyan