You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@singa.apache.org by zh...@apache.org on 2022/06/01 08:43:32 UTC

[singa] branch dev updated: update the runtime Dockerfile for v3.3

This is an automated email from the ASF dual-hosted git repository.

zhaojing pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/singa.git


The following commit(s) were added to refs/heads/dev by this push:
     new 1e90f1ea update the runtime Dockerfile for v3.3
     new 153c6ae2 Merge pull request #969 from lzjpaul/22-6-1-update-dockerfile
1e90f1ea is described below

commit 1e90f1ea1677b646e2acd467826b4a110949731a
Author: zhaojing <zh...@comp.nus.edu.sg>
AuthorDate: Wed Jun 1 16:27:23 2022 +0800

    update the runtime Dockerfile for v3.3
---
 tool/docker/runtime/cpu/Dockerfile | 36 ++---------------------------------
 tool/docker/runtime/gpu/Dockerfile | 39 ++++----------------------------------
 2 files changed, 6 insertions(+), 69 deletions(-)

diff --git a/tool/docker/runtime/cpu/Dockerfile b/tool/docker/runtime/cpu/Dockerfile
index d418e620..27972656 100644
--- a/tool/docker/runtime/cpu/Dockerfile
+++ b/tool/docker/runtime/cpu/Dockerfile
@@ -16,40 +16,8 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 #
-# Base unbuntu 16.04 image
-FROM ubuntu:18.04
+FROM python:3.7-slim-bullseye
 
 MAINTAINER singa dev@singa.apache.org
 
-# install dependencies
-RUN apt-get update \
-    && apt-get install -y --no-install-recommends subversion git wget openssh-server bzip2 \
-    && apt-get clean && apt-get autoremove && apt-get autoclean \
-    && rm -rf /var/lib/apt/lists/*
-
-# install conda
-RUN wget --no-check-certificate https://repo.continuum.io/miniconda/Miniconda3-py37_4.8.2-Linux-x86_64.sh -O miniconda.sh
-RUN bash miniconda.sh -b -p /root/miniconda
-ENV PATH /root/miniconda/bin:${PATH}
-RUN conda config --set always_yes yes --set changeps1 no
-RUN conda config --add channels conda-forge
-RUN conda config --add channels nusdbsystem
-RUN conda install -c nusdbsystem singa-cpu
-RUN conda install -c conda-forge sphinx
-RUN conda install -c conda-forge sphinx_rtd_theme
-RUN conda install -c conda-forge recommonmark
-
-
-# config ssh service
-RUN mkdir /var/run/sshd \
-    && echo 'root:singa' | chpasswd \
-    && sed -ri 's/^#?PermitRootLogin\s+.*/PermitRootLogin yes/' /etc/ssh/sshd_config \
-    && sed -ri 's/UsePAM yes/#UsePAM yes/g' /etc/ssh/sshd_config \
-    && mkdir /root/.ssh
-
-# add conda bin path to login or non-login shell
-RUN echo PATH=$PATH:/root/miniconda/bin >> /etc/profile
-
-EXPOSE 22
-
-CMD ["/usr/sbin/sshd", "-D"]
+RUN pip install singa -f http://singa.apache.org/docs/next/wheel-cpu.html --trusted-host singa.apache.org
diff --git a/tool/docker/runtime/gpu/Dockerfile b/tool/docker/runtime/gpu/Dockerfile
index 009efc3e..59b39d86 100644
--- a/tool/docker/runtime/gpu/Dockerfile
+++ b/tool/docker/runtime/gpu/Dockerfile
@@ -16,41 +16,10 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 #
-# Base unbuntu 16.04 image
-FROM nvidia/cuda:9.0-devel-ubuntu16.04
+FROM nvidia/cuda:10.2-base-ubuntu18.04
 
 MAINTAINER singa dev@singa.apache.org
 
-# install dependencies
-RUN apt-get update \
-    && apt-get install -y --no-install-recommends subversion git wget openssh-server bzip2 \
-    && apt-get clean && apt-get autoremove && apt-get autoclean \
-    && rm -rf /var/lib/apt/lists/*
-
-# install conda
-RUN wget --no-check-certificate https://repo.continuum.io/miniconda/Miniconda3-py37_4.8.2-Linux-x86_64.sh -O miniconda.sh;
-RUN bash miniconda.sh -b -p /root/miniconda
-ENV PATH /root/miniconda/bin:${PATH}
-RUN conda config --set always_yes yes --set changeps1 no
-RUN conda config --add channels conda-forge
-RUN conda config --add channels nusdbsystem
-RUN conda install -c conda-forge -c nusdbsystem singa-gpu
-RUN conda install -c conda-forge sphinx
-RUN conda install -c conda-forge sphinx_rtd_theme
-RUN conda install -c conda-forge recommonmark
-
-
-# config ssh service
-RUN mkdir /var/run/sshd \
-    && echo 'root:singa' | chpasswd \
-    && sed -ri 's/^#?PermitRootLogin\s+.*/PermitRootLogin yes/' /etc/ssh/sshd_config \
-    && sed -ri 's/UsePAM yes/#UsePAM yes/g' /etc/ssh/sshd_config \
-    && mkdir /root/.ssh
-
-# add conda bin path to login or non-login shell
-RUN echo PATH=$PATH:/root/miniconda/bin >> /etc/profile
-
-
-EXPOSE 22
-
-CMD ["/usr/sbin/sshd", "-D"]
+RUN apt-get update && apt-get install -y --no-install-recommends python3 python3-pip 
+RUN pip3 install --upgrade pip
+RUN pip install singa -f http://singa.apache.org/docs/next/wheel-gpu.html --trusted-host singa.apache.org
\ No newline at end of file