Dockerfile 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. # Copyright (c) 2021 NVIDIA Corporation. All rights reserved.
  2. # To build the docker container, run: $ sudo docker build -t openacc-labs:latest .
  3. # To run: $ sudo docker run --rm -it --runtime nvidia -p 8888:8888 openacc-labs:latest
  4. # Finally, open http://localhost:8888/
  5. FROM nvcr.io/nvidia/nvhpc:20.11-devel-cuda_multi-ubuntu20.04
  6. RUN apt-get -y update && \
  7. DEBIAN_FRONTEND=noninteractive apt-get -yq install --no-install-recommends python3-pip python3-setuptools nginx zip make build-essential libtbb-dev && \
  8. rm -rf /var/lib/apt/lists/* && \
  9. pip3 install --upgrade pip &&\
  10. pip3 install --no-cache-dir jupyter &&\
  11. pip3 install gdown
  12. ############################################
  13. # NVIDIA nsight-systems-2020.5.1 ,nsight-compute-2
  14. RUN apt-get update -y && \
  15. DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
  16. apt-transport-https \
  17. ca-certificates \
  18. gnupg \
  19. wget && \
  20. apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys F60F4B3D7FA2AF80 && \
  21. echo "deb https://developer.download.nvidia.com/devtools/repos/ubuntu2004/amd64/ /" >> /etc/apt/sources.list.d/nsight.list &&\
  22. apt-get update -y
  23. RUN DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends nsight-systems-2020.5.1 nsight-compute-2020.2.1
  24. # TO COPY the data
  25. COPY nways_labs/ /labs/
  26. RUN python3 /labs/nways_MD/English/C/source_code/dataset.py
  27. #################################################
  28. ENV LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/lib:/opt/nvidia/hpc_sdk/Linux_x86_64/20.11/cuda/11.0/lib64/"
  29. ENV PATH="/opt/nvidia/nsight-systems/2020.5.1/bin:/opt/nvidia/nsight-compute/2020.2.1:/opt/nvidia/hpc_sdk/Linux_x86_64/20.11/cuda/11.0/include:/usr/local/bin:/opt/anaconda3/bin:/usr/bin:$PATH"
  30. #################################################
  31. ADD nways_labs/ /labs
  32. WORKDIR /labs
  33. CMD service nginx start && jupyter notebook --no-browser --allow-root --ip=0.0.0.0 --port=8888 --NotebookApp.token="" --notebook-dir=/labs