Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an Ubuntu 24.04 image with CUDA #103

Merged
merged 1 commit into from
May 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
- ubuntu2204_cpp20
- ubuntu2204_rocm_clang
- ubuntu2404
- ubuntu2404_cuda
- centos7-base
- centos8-base
steps:
Expand Down Expand Up @@ -102,4 +103,3 @@ jobs:
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=registry,ref=ghcr.io/${{ github.repository_owner }}/${{ matrix.context }}:buildcache
cache-to: type=registry,ref=ghcr.io/${{ github.repository_owner }}/${{ matrix.context }}:buildcache,mode=max

30 changes: 30 additions & 0 deletions ubuntu2404_cuda/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
FROM ghcr.io/acts-project/ubuntu2404:47

LABEL description="Ubuntu 24.04 with Acts dependencies and CUDA"
LABEL maintainer="Stephen Nicholas Swatman <[email protected]>"
# increase whenever any of the RUN commands change
LABEL version="1"

# DEBIAN_FRONTEND ensures non-blocking operation (tzdata is a problem)
ENV DEBIAN_FRONTEND noninteractive

ENV CUDA_RUNFILE_NAME="cuda_12.5.0_555.42.02_linux.run"
ENV CUDA_INSTALL_PATH="/usr/local/cuda"

RUN apt install wget

RUN wget https://developer.download.nvidia.com/compute/cuda/12.5.0/local_installers/${CUDA_RUNFILE_NAME} && \
chmod +x ${CUDA_RUNFILE_NAME} && \
./${CUDA_RUNFILE_NAME} --toolkit --silent --installpath=${CUDA_INSTALL_PATH} && \
rm ${CUDA_RUNFILE_NAME}
Comment on lines +14 to +19
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am super not on board with this implementation. Please don't merge stuff right away, and wait for us to have a look first!

You'll need to switch to the same setup that I use for all the other GPU supporting images. Installing CUDA/HIP/oneAPI using APT. Since that's the one technique that all of them support. So let's not install each of them in a different way!

I.e. go and modify this image like: https://github.com/acts-project/machines/blob/master/ubuntu2004_cuda/Dockerfile


ENV CUDA_PATH="${CUDA_INSTALL_PATH}"
ENV CUDA_ROOT="${CUDA_INSTALL_PATH}"
ENV CUDA_HOME="${CUDA_INSTALL_PATH}"
ENV CUDACXX="${CUDA_INSTALL_PATH}/bin/nvcc"
ENV CUDACC="${CUDA_INSTALL_PATH}/bin/nvcc"

ENV PATH="${CUDA_INSTALL_PATH}/bin:${PATH}"
ENV MANPATH="${CUDA_INSTALL_PATH}/share/man:${MANPATH}"
ENV INCLUDE="${CUDA_INSTALL_PATH}/include:${INCLUDE}"
ENV LD_LIBRARY_PATH="${CUDA_INSTALL_PATH}/lib64:${CUDA_INSTALL_PATH}/lib:${LD_LIBRARY_PATH}"
Loading