forked from Tensor-Array/Tensor-Array
-
Notifications
You must be signed in to change notification settings - Fork 0
52 lines (45 loc) · 1.41 KB
/
docker-publish-d.yml
File metadata and controls
52 lines (45 loc) · 1.41 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: Publish Docker image
on:
release:
type: [published]
jobs:
push_to_registry:
name: Push Docker image
runs-on: ubuntu-22.04
strategy:
matrix:
image-tag: [ "CUDA-12.9.1-Ubuntu-2004", "CUDA-12.9.1-ubi8" ]
permissions:
packages: write
contents: read
attestations: write
id-token: write
steps:
- name: Check out the repo
uses: actions/checkout@v4
- name: Docker Login
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Docker Metadata action
id: meta
uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804
with:
image: ${{ secrets.DOCKER_USERNAME }}/tensor-array
tags: ${{ matrix.image-tag }}
- name: Build and push Docker images
id: push
uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83
with:
context: .
file: ./Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
- name: Attest Build Provenance
uses: actions/attest-build-provenance@v2
with:
subject-name: index.docker.io/${{ secrets.DOCKER_USERNAME }}/tensor-array
subject-digest: ${{ steps.push.outputs.digest }}
push-to-registry: true