-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (30 loc) · 1.04 KB
/
build-image.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Docker Image CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
cuda_major_version: ['11']
cuda_minor_version: ['3', '7', '8']
cuda_patch_version: ['0', '1']
exclude:
- cuda_minor_version: '8'
cuda_patch_version: '1'
steps:
- uses: actions/checkout@v3
- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build the Docker image
env:
PUSH_COMMAND: ${{ github.ref =='refs/heads/main' && '--push' || '' }}
run: |
bash ./build.sh -d --image-name ${{ secrets.DOCKERHUB_ORG }}/cudagl --cuda-version ${{ matrix.cuda_major_version }}.${{ matrix.cuda_minor_version}}.${{ matrix.cuda_patch_version }} --os ubuntu --os-version 20.04 --arch x86_64 --cudagl ${{ env. PUSH_COMMAND }}