Skip to content

Commit 19bd62b

Browse files
committed
fix: enable NNI on production kernels
1 parent ae709b7 commit 19bd62b

File tree

5 files changed

+41
-8
lines changed

5 files changed

+41
-8
lines changed

python-ff/Dockerfile.20.07-py36-cuda10.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ LABEL ai.backend.kernelspec="1" \
116116
ai.backend.resource.min.cuda.shares=0 \
117117
ai.backend.runtime-type="python" \
118118
ai.backend.runtime-path="/usr/bin/python3" \
119-
ai.backend.service-ports="ipython:pty:3000,jupyter:http:8080,jupyterlab:http:8090,vscode:http:8180,tensorboard:http:6006,mlflow-ui:http:5000"
119+
ai.backend.service-ports="ipython:pty:3000,jupyter:http:8091,jupyterlab:http:8090,vscode:http:8180,tensorboard:http:6006,mlflow-ui:http:5000,nniboard:http:8080"
120120

121121
WORKDIR /home/work
122122
# vim: ft=dockerfile

python-ff/Dockerfile.20.08-py36-cuda10.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ LABEL ai.backend.kernelspec="1" \
114114
ai.backend.resource.min.cuda.shares=0 \
115115
ai.backend.runtime-type="python" \
116116
ai.backend.runtime-path="/usr/bin/python3" \
117-
ai.backend.service-ports="ipython:pty:3000,jupyter:http:8080,jupyterlab:http:8090,vscode:http:8180,tensorboard:http:6006"
117+
ai.backend.service-ports="ipython:pty:3000,jupyter:http:8091,jupyterlab:http:8090,vscode:http:8180,tensorboard:http:6006,mlflow-ui:http:5000,nniboard:http:8080"
118118

119119
WORKDIR /home/work
120120
# vim: ft=dockerfile

r-base/Dockerfile.3.6

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,8 @@ RUN jupyter nbextensions_configurator enable && \
112112
jupyter labextension install --no-build jupyterlab-nvdashboard && \
113113
jupyter lab build
114114

115+
COPY ./service-defs /etc/backend.ai/service-defs
116+
115117
LABEL ai.backend.kernelspec="1" \
116118
ai.backend.envs.corecount="OPENBLAS_NUM_THREADS,OMP_NUM_THREADS,NPROC" \
117119
ai.backend.features="batch query uid-match user-input" \
@@ -122,4 +124,4 @@ LABEL ai.backend.kernelspec="1" \
122124
ai.backend.runtime-path="/usr/bin/python3" \
123125
ai.backend.service-ports="ipython:pty:3000,jupyter:http:8080,jupyterlab:http:8090"
124126

125-
WORKDIR /home/work
127+
WORKDIR /home/work

r-base/Dockerfile.4.0.2

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,15 +111,19 @@ RUN jupyter nbextensions_configurator enable && \
111111
# jupyter labextension install @jupyterlab/hdf5
112112
jupyter labextension install --no-build jupyterlab-nvdashboard && \
113113
jupyter lab build
114+
RUN ln -s /usr/lib/x86_64-linux-gnu/libffi.so.7 /usr/lib/x86_64-linux-gnu/libffi.so.6
115+
#RUN ln -s /usr/lib/x86_64-linux-gnu/libssl.so /usr/lib/x86_64-linux-gnu/libssl.so.1.0.0
116+
117+
COPY ./service-defs /etc/backend.ai/service-defs
114118

115119
LABEL ai.backend.kernelspec="1" \
116120
ai.backend.envs.corecount="OPENBLAS_NUM_THREADS,OMP_NUM_THREADS,NPROC" \
117121
ai.backend.features="batch query uid-match user-input" \
118122
ai.backend.resource.min.cpu="1" \
119123
ai.backend.resource.min.mem="256m" \
120-
ai.backend.base-distro="ubuntu16.04" \
124+
ai.backend.base-distro="ubuntu20.04" \
121125
ai.backend.runtime-type="r" \
122126
ai.backend.runtime-path="/usr/bin/python3" \
123127
ai.backend.service-ports="ipython:pty:3000,jupyter:http:8080,jupyterlab:http:8090"
124128

125-
WORKDIR /home/work
129+
WORKDIR /home/work

ubuntu/Dockerfile.18.04.xfce.amd64

Lines changed: 30 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,22 +81,49 @@ RUN ln -sf /usr/local/lib/web/frontend/static/websockify /usr/local/lib/web/fron
8181
RUN ln -sf /usr/local/lib/web/frontend/static/vnc.html /usr/local/lib/web/frontend/static/index.html
8282
RUN ln -sf /usr/local/lib/web/frontend/static/novnc/vnc.html /usr/local/lib/web/frontend/static/novnc/index.html
8383

84+
####### Install CUDA for GPU acceleration
85+
RUN apt update \
86+
&& apt-get -y --install-recommends install wget dirmngr \
87+
&& wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/cuda-ubuntu1804.pin \
88+
&& mv cuda-ubuntu1804.pin /etc/apt/preferences.d/cuda-repository-pin-600 \
89+
&& wget http://developer.download.nvidia.com/compute/cuda/10.2/Prod/local_installers/cuda-repo-ubuntu1804-10-2-local-10.2.89-440.33.01_1.0-1_amd64.deb \
90+
&& dpkg -i cuda-repo-ubuntu1804-10-2-local-10.2.89-440.33.01_1.0-1_amd64.deb \
91+
&& apt-key add /var/cuda-repo-10-2-local-10.2.89-440.33.01/7fa2af80.pub \
92+
&& apt-get -y update \
93+
&& apt-get -y install cuda \
94+
&& apt autoclean -y \
95+
&& apt autoremove -y \
96+
&& rm -rf /var/lib/apt/lists/*
97+
98+
####### XRDP
99+
RUN apt update \
100+
&& apt install -y --no-install-recommends --allow-unauthenticated \
101+
xrdp \
102+
&& apt autoclean -y \
103+
&& apt autoremove -y \
104+
&& rm -rf /var/lib/apt/lists/*
105+
106+
####### Last setup
107+
84108
EXPOSE 80
85109

86110
ENV HOME=/home/work \
87111
SHELL=/bin/bash
88-
HEALTHCHECK --interval=30s --timeout=5s CMD curl --fail http://127.0.0.1:6079/api/health
112+
#HEALTHCHECK --interval=30s --timeout=5s CMD curl --fail http://127.0.0.1:6079/api/health
89113

90114
# Backend.AI specifics
91115
LABEL ai.backend.kernelspec="1" \
92116
ai.backend.envs.corecount="OPENBLAS_NUM_THREADS,OMP_NUM_THREADS,NPROC" \
93-
ai.backend.features="batch query uid-match user-input" \
117+
ai.backend.features="uid-match" \
118+
ai.backend.accelerators="cuda" \
94119
ai.backend.resource.min.cpu="1" \
95120
ai.backend.resource.min.mem="1g" \
121+
ai.backend.resource.min.cuda.device="0" \
122+
ai.backend.resource.min.cuda.shares="0" \
96123
ai.backend.resource.preferred.shmem="512m" \
97124
ai.backend.base-distro="ubuntu18.04" \
98125
ai.backend.runtime-type="app" \
99-
ai.backend.service-ports="xfce:http:80,vnc:http:5900"
126+
ai.backend.service-ports="xfce:http:80,vnc:http:5900,xrdp:http:3389"
100127

101128
COPY ./service-defs /etc/backend.ai/service-defs
102129
COPY policy.yml /etc/backend.ai/jail/policy.yml

0 commit comments

Comments
 (0)