Skip to content

Commit

Permalink
adding aarch64
Browse files Browse the repository at this point in the history
  • Loading branch information
ameli committed Dec 13, 2023
1 parent 804c5f6 commit ba14f80
Show file tree
Hide file tree
Showing 20 changed files with 927 additions and 31 deletions.
21 changes: 21 additions & 0 deletions .cirrus.star
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# SPDX-FileCopyrightText: Copyright 2021, Siavash Ameli <sameli@berkeley.edu>
# SPDX-License-Identifier: BSD-3-Clause
# SPDX-FileType: SOURCE
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the license found in the LICENSE.txt file in the root
# directory of this source tree.


load("cirrus", "env", "fs", "http")

def main(ctx):

file = ''
file += fs.read("tools/ci/cirrus_deploy_docker_manylinux2014_aarch64_cuda_12.3.yml")
# file += fs.read("tools/ci/cirrus_deploy_pypi_linux_aarch64.yml")
# file += fs.read("tools/ci/cirrus_deploy_pypi_macosx_arm64.yml")
# file += fs.read("tools/ci/cirrus_deploy_conda_linux_aarch64.yml")
# file += fs.read("tools/ci/cirrus_deploy_conda_macosx_arm64.yml")

return file
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: deploy-docker-10-2
name: deploy-docker-manylinux2014_x86_64_cuda_10.2

on:
push:
Expand All @@ -9,7 +9,7 @@ on:
- published

jobs:
build-cuda-10-2:
build-manylinux_x86_64_cuda_10_2:
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -21,12 +21,12 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Cuda-10.2
- name: Build and push manylinux2014_x86_64_cuda-10.2
id: docker_build
uses: docker/build-push-action@v3
with:
push: true
file: ./docker/cuda-10.2/Dockerfile
file: ./docker/manylinux2014_x86_64_cuda_10.2/Dockerfile
tags: sameli/manylinux2014_x86_64_cuda_10.2:latest

- name: Image digest
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: deploy-docker-11-7
name: deploy-docker-manylinux2014_x86_64_cuda_11.7

on:
push:
Expand All @@ -9,7 +9,7 @@ on:
- published

jobs:
build-cuda-11-7:
build-manylinux_x86_64_cuda_11_7:
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -21,12 +21,12 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Cuda-11.7
- name: Build and push manylinux2014_x86_64_cuda-11.7
id: docker_build
uses: docker/build-push-action@v3
with:
push: true
file: ./docker/cuda-11.7/Dockerfile
file: ./docker/manylinux2014_x86_64_cuda_11.7/Dockerfile
tags: sameli/manylinux2014_x86_64_cuda_11.7:latest

- name: Image digest
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: deploy-docker-11-8
name: deploy-docker-manylinux2014_x86_64_cuda_11.8

on:
push:
Expand All @@ -9,7 +9,7 @@ on:
- published

jobs:
build-cuda-11-8:
build-manylinux_x86_64_cuda_11_8:
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -21,12 +21,12 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Cuda-11.8
- name: Build and push manylinux2014_x86_64_cuda-11.8
id: docker_build
uses: docker/build-push-action@v3
with:
push: true
file: ./docker/cuda-11.8/Dockerfile
file: ./docker/manylinux2014_x86_64_cuda_11.8/Dockerfile
tags: sameli/manylinux2014_x86_64_cuda_11.8:latest

- name: Image digest
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: deploy-docker-12-0
name: deploy-docker-manylinux2014_x86_64_cuda_12.0

on:
push:
Expand All @@ -9,7 +9,7 @@ on:
- published

jobs:
build-cuda-12-0:
build-manylinux_x86_64_cuda_12_0:
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -21,12 +21,12 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Cuda-12.0
- name: Build and push manylinux2014_x86_64_cuda-12.0
id: docker_build
uses: docker/build-push-action@v3
with:
push: true
file: ./docker/cuda-12.0/Dockerfile
file: ./docker/manylinux2014_x86_64_cuda_12.0/Dockerfile
tags: sameli/manylinux2014_x86_64_cuda_12.0:latest

- name: Image digest
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: deploy-docker-12-2
name: deploy-docker-manylinux2014_x86_64_cuda_12.2

on:
push:
Expand All @@ -9,7 +9,7 @@ on:
- published

jobs:
build-cuda-12-2:
build-manylinux_x86_64_cuda_12_2:
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -21,12 +21,12 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Cuda-12.2
- name: Build and push manylinux2014_x86_64_cuda-12.2
id: docker_build
uses: docker/build-push-action@v3
with:
push: true
file: ./docker/cuda-12.2/Dockerfile
file: ./docker/manylinux2014_x86_64_cuda_12.2/Dockerfile
tags: sameli/manylinux2014_x86_64_cuda_12.2:latest

- name: Image digest
Expand Down
18 changes: 17 additions & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -190,10 +190,26 @@ Push to Dockerhub:
docker login
docker-compose push

Troubleshooting
===============

When running the docker container in Github action, you may encounter this error:

::

no space left on device.

To resolve this, try clearing the Github's runner cache before executing the docker container:

::

- name: Clear Cache
run: rm -rf /opt/hostedtoolcache

Other CUDA Versions
===================

To request a docker image for a specific CUDA version, feel free to create a `GitHub issue <https://github.com/ameli/manylinux-cuda/issues>`_.
To request a docker image for a specific CUDA version, feel free to create a `GitHub issue <https://github.com/ameli/manylinux-cuda/issues>`__.

License
=======
Expand Down
20 changes: 10 additions & 10 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
version: '3'
services:
cuda_10.2:
build: ./docker/cuda-10.2
manylinux2014_x86_64_cuda_10.2:
build: ./docker/manylinux2014_x86_64_cuda_10.2
image: sameli/manylinux2014_x86_64_cuda_10.2

cuda_11.7:
build: ./docker/cuda-11.7
manylinux2014_x86_64_cuda_11.7:
build: ./docker/manylinux2014_x86_64_cuda_11.7
image: sameli/manylinux2014_x86_64_cuda_11.7

cuda_11.8:
build: ./docker/cuda-11.8
manylinux2014_x86_64_cuda_11.8:
build: ./docker/manylinux2014_x86_64_cuda_11.8
image: sameli/manylinux2014_x86_64_cuda_11.8

cuda_12.0:
build: ./docker/cuda-12.0
manylinux2014_x86_64_cuda_12.0:
build: ./docker/manylinux2014_x86_64_cuda_12.0
image: sameli/manylinux2014_x86_64_cuda_12.0

cuda_12.2:
build: ./docker/cuda-12.2
manylinux2014_x86_64_cuda_12.2:
build: ./docker/manylinux2014_x86_64_cuda_12.2
image: sameli/manylinux2014_x86_64_cuda_12.2
51 changes: 51 additions & 0 deletions docker/manylinux2014_aarch64_cuda_12.3/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# SPDX-FileCopyrightText: Copyright 2021, Siavash Ameli <sameli@berkeley.edu>
# SPDX-License-Identifier: BSD-3-Clause
# SPDX-FileType: SOURCE

# -----------------------------------------------------------------------------
# How to build
# $ docker build -t sameli/manylinux2014_aarch64_cuda_12.3 -f <This-Filename> .
#
# How to run:
# $ docker run -it -v/host_dir:/image_dir --entrypoint /bin/bash \
# manylinux2014_aarch64_cuda_12.3
# -----------------------------------------------------------------------------

# -----------------
# Choose base image
# -----------------

FROM quay.io/pypa/manylinux2014_aarch64

MAINTAINER Siavash Ameli <samei@berkeley.edu>
LABEL Description="manylinux2014_aarch64 with cuda 12.3"

# ------------
# Install cuda
# ------------

RUN dnf install -y dnf-utils
RUN dnf install -y wget

RUN wget https://developer.download.nvidia.com/compute/cuda/12.3.1/local_installers/cuda-repo-rhel9-12-3-local-12.3.1_545.23.08-1.aarch64.rpm
RUN sudo rpm -i cuda-repo-rhel9-12-3-local-12.3.1_545.23.08-1.aarch64.rpm
RUN sudo dnf clean all
RUN sudo dnf -y install cuda-toolkit-12-3
RUN rm cuda-repo-rhel9-12-3-local-12.3.1_545.23.08-1.aarch64.rpm

# -------------------------
# Set environment variables
# -------------------------

ENV PATH="/usr/local/cuda/bin:${PATH}"
ENV CUDA_HOME=/usr/local/cuda
ENV CUDA_ROOT=/usr/local/cuda
ENV CUDA_PATH=/usr/local/cuda
ENV CUDADIR=/usr/local/cuda
ENV LD_LIBRARY_PATH="/usr/local/cuda/lib64:${LD_LIBRARY_PATH}"

# --------
# Commands
# --------

CMD ["/bin/bash"]
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit ba14f80

Please sign in to comment.