persistent environments, remove useless comment
- persistent environments from nvidia into /etc/profile.d/00-nvidia.sh - add git and neovim as per-installed programs
This commit is contained in:
parent
e5cf132d93
commit
a82843e942
10
Dockerfile
10
Dockerfile
|
@ -4,13 +4,21 @@ ARG APT_MIRROR=https://mirrors.bfsu.edu.cn
|
|||
ARG ROOT_PASSWD=miao
|
||||
|
||||
RUN \
|
||||
env | grep -E -e '^NVIDIA' -e '^NV_' -e '^NVARCH' -e '^NCCL_' | \
|
||||
sed -E 's/=(.*)/="\1"/' > \
|
||||
/etc/profile.d/00-nvidia.sh && \
|
||||
echo "PATH=/usr/local/nvidia/bin:/usr/local/cuda/bin:\${PATH}" >> /etc/profile.d/00-nvidia.sh && \
|
||||
echo "LD_LIBRARY_PATH=/usr/local/nvidia/lib:/usr/local/nvidia/lib64" >> /etc/profile.d/00-nvidia.sh && \
|
||||
echo "LIBRARY_PATH=/usr/local/cuda/lib64/stubs" >> /etc/profile.d/00-nvidia.sh && \
|
||||
sed -i 's/^/export /' /etc/profile.d/00-nvidia.sh && \
|
||||
\
|
||||
sed -i "s#http://archive.ubuntu.com#${APT_MIRROR}#g" /etc/apt/sources.list && \
|
||||
sed -i "s#http://security.ubuntu.com#${APT_MIRROR}#g" /etc/apt/sources.list && \
|
||||
\
|
||||
echo root:${ROOT_PASSWD} | chpasswd && \
|
||||
\
|
||||
apt update && \
|
||||
apt install --yes ssh tini && \
|
||||
apt install --yes ssh tini neovim git && \
|
||||
apt clean && \
|
||||
rm -rf /var/lib/apt/lists/* && \
|
||||
\
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
#--rm --device nvidia.com/gpu=all -it docker.io/nvidia/cuda:11.8.0-devel-ubuntu22.04 bash
|
||||
version: "3.9"
|
||||
name: "mcuda"
|
||||
services:
|
||||
|
|
Loading…
Reference in a new issue