Singularity 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. # Copyright (c) 2020 NVIDIA Corporation. All rights reserved.
  2. Bootstrap: docker
  3. FROM: nvcr.io/nvidia/nvhpc:20.9-devel-ubuntu20.04
  4. %environment
  5. export XDG_RUNTIME_DIR=
  6. export PATH="$PATH:/usr/local/bin:/opt/anaconda3/bin:/usr/bin"
  7. export PATH=/opt/nvidia/nsight-systems/2020.2.1/bin:$PATH
  8. export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/lib:/opt/nvidia/hpc_sdk/Linux_x86_64/20.9/cuda/11.0/lib64/"
  9. %post
  10. build_tmp=$(mktemp -d) && cd ${build_tmp}
  11. apt-get -y update
  12. apt-get -y dist-upgrade
  13. DEBIAN_FRONTEND=noninteractive apt-get -yq install --no-install-recommends \
  14. m4 vim-nox emacs-nox nano zip\
  15. python3-pip python3-setuptools git-core inotify-tools \
  16. curl git-lfs \
  17. build-essential
  18. rm -rf /var/lib/apt/cache/*
  19. pip3 install --upgrade pip
  20. apt-get update -y
  21. apt-get -y install git nvidia-modprobe
  22. pip3 install jupyterlab
  23. pip3 install ipywidgets
  24. pip3 install jupyter netcdf4
  25. apt-get install --no-install-recommends -y build-essential
  26. # NVIDIA nsight-systems-2020.2.1
  27. apt-get update -y
  28. DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends apt-transport-https ca-certificates gnupg wget
  29. apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys F60F4B3D7FA2AF80
  30. echo "deb https://developer.download.nvidia.com/devtools/repo-deb/x86_64/ /" >> /etc/apt/sources.list.d/nsight.list
  31. apt-get update -y
  32. DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends nsight-systems-2020.2.1
  33. apt-get install --no-install-recommends -y build-essential
  34. wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
  35. bash Miniconda3-latest-Linux-x86_64.sh -b -p /opt/anaconda3
  36. rm Miniconda3-latest-Linux-x86_64.sh
  37. /opt/anaconda3/bin/conda install -y -q netcdf4
  38. cd /
  39. rm -rf ${build_tmp}
  40. %files
  41. English/ /labs
  42. %runscript
  43. "$@"
  44. %labels
  45. AUTHOR mozhgank