diff --git a/Dockerfile b/Dockerfile index db881013..d9b6e3c3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -28,7 +28,10 @@ ENV LC_ALL=en_US.UTF-8 \ # Install all OS dependencies for notebook server that starts but lacks all # features (e.g., download as all possible file formats) -RUN apt-get update --yes && \ +RUN \ + apt-get update --yes && \ + apt-get install --yes --no-install-recommends pciutils && \ + _CUDA_=$(lspci -nn | grep '\[03' | grep NVIDIA) && \ apt-get install --yes --no-install-recommends \ #fonts-liberation, pandoc, run-one are inherited from base-notebook container image # Other "our" apt installs @@ -45,7 +48,7 @@ RUN apt-get update --yes && \ emacs \ # CUDA #cuda \ - nvidia-cuda-toolkit \ + $([ -n "$_CUDA_" ] && echo nvidia-cuda-toolkit) \ && \ apt-get clean && rm -rf /var/lib/apt/lists/* && \ echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && \