-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile_old
50 lines (42 loc) · 1.06 KB
/
Dockerfile_old
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
39
40
41
42
43
44
45
46
47
48
49
50
FROM nvidia/cuda:11.2.2-base-ubuntu20.04
# Set variables
ARG UBUNTU_VERSION=focal
ARG R_HOME=/usr/lib/R
ARG DEBIAN_FRONTEND=noninteractive
ENV DEBIAN_FRONTEND=noninteractive
# Install dependencies
RUN apt-get update && apt-get install -y \
curl \
ca-certificates \
dumb-init \
htop \
sudo \
gcc \
bzip2 \
libx11-6 \
locales \
man \
git \
procps \
openssh-client \
lsb-release \
&& rm -rf /var/lib/apt/lists/*
# Install R
COPY install_R.sh /tmp/install_R.sh
RUN . /tmp/install_R.sh
# https://wiki.debian.org/Locale#Manually
RUN sed -i "s/# en_US.UTF-8/en_US.UTF-8/" /etc/locale.gen \
&& locale-gen
ENV LANG=en_US.UTF-8
# Create project directory
RUN mkdir /projects
RUN adduser --gecos '' --disabled-password coder && \
echo "coder ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers.d/nopasswd
# Install Rstudio
COPY install_rstudio.sh /tmp/install_rstudio.sh
RUN . /tmp/install_rstudio.sh
COPY userconf.sh /etc/cont-init.d/userconf
EXPOSE 8888
#CMD ["/init"]
CMD ["/init"]
# docker run --gpus all --rm -ti rocker/ml-gpu R