-
Notifications
You must be signed in to change notification settings - Fork 2.1k
119 lines (110 loc) · 4.07 KB
/
build-docker-from-tag.yml
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
name: Build Image from tag
on:
workflow_call:
inputs:
tag_name:
description: "Tag of an image to built"
type: string
required: true
workflow_dispatch:
inputs:
tag_name:
description: "Tag of an image to built"
type: string
required: true
push:
tags:
- core-v**
- prover-v**
- contract_verifier-v**
concurrency: docker-build
jobs:
setup:
name: Setup
runs-on: [ ubuntu-latest ]
outputs:
image_tag_suffix: ${{ steps.set.outputs.image_tag_suffix }}
prover_fri_gpu_key_id: ${{ steps.extract-prover-fri-setup-key-ids.outputs.gpu_short_commit_sha }}
steps:
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4
- name: Generate output with git tag
id: set
run: |
git_tag=""
if [[ -z "${{ inputs.tag_name }}" ]]; then
git_tag="${GITHUB_REF#refs/*/}"
else
git_tag="${{ inputs.tag_name }}"
fi
version=$(cut -d "-" -f2 <<< ${git_tag})
echo "image_tag_suffix=${version}" >> $GITHUB_OUTPUT
- name: Generate outputs with Prover FRI setup data keys IDs
id: extract-prover-fri-setup-key-ids
run: |
./prover/extract-setup-data-keys.sh >> $GITHUB_OUTPUT
build-push-core-images:
name: Build and push image
needs: [ setup ]
uses: ./.github/workflows/build-core-template.yml
if: contains(github.ref_name, 'core')
secrets:
DOCKERHUB_USER: ${{ secrets.DOCKERHUB_USER }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
with:
image_tag_suffix: ${{ needs.setup.outputs.image_tag_suffix }}
en_alpha_release: true
build-push-tee-prover-images:
name: Build and push images
needs: [ setup ]
uses: ./.github/workflows/build-tee-prover-template.yml
if: contains(github.ref_name, 'core')
secrets:
DOCKERHUB_USER: ${{ secrets.DOCKERHUB_USER }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
ATTIC_TOKEN: ${{ secrets.ATTIC_TOKEN }}
with:
image_tag_suffix: ${{ needs.setup.outputs.image_tag_suffix }}
build-push-contract-verifier:
name: Build and push image
needs: [ setup ]
uses: ./.github/workflows/build-contract-verifier-template.yml
if: contains(github.ref_name, 'contract_verifier')
secrets:
DOCKERHUB_USER: ${{ secrets.DOCKERHUB_USER }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
with:
image_tag_suffix: ${{ needs.setup.outputs.image_tag_suffix }}
build-push-prover-images:
name: Build and push image
needs: [ setup ]
uses: ./.github/workflows/build-prover-template.yml
if: contains(github.ref_name, 'prover')
with:
image_tag_suffix: ${{ needs.setup.outputs.image_tag_suffix }}
ERA_BELLMAN_CUDA_RELEASE: ${{ vars.ERA_BELLMAN_CUDA_RELEASE }}
CUDA_ARCH: "60;70;75;80;89"
secrets:
DOCKERHUB_USER: ${{ secrets.DOCKERHUB_USER }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
build-push-witness-generator-image-avx512:
name: Build and push image
needs: [ setup ]
uses: ./.github/workflows/build-witness-generator-template.yml
if: contains(github.ref_name, 'prover')
with:
image_tag_suffix: ${{ needs.setup.outputs.image_tag_suffix }}-avx512
ERA_BELLMAN_CUDA_RELEASE: ${{ vars.ERA_BELLMAN_CUDA_RELEASE }}
CUDA_ARCH: "60;70;75;80;89"
WITNESS_GENERATOR_RUST_FLAGS: "-Ctarget_feature=+avx512bw,+avx512cd,+avx512dq,+avx512f,+avx512vl"
secrets:
DOCKERHUB_USER: ${{ secrets.DOCKERHUB_USER }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
build-gar-prover-fri-gpu-and-circuit-prover-gpu-gar:
name: Build GAR prover FRI GPU
needs: [ setup, build-push-prover-images ]
uses: ./.github/workflows/build-prover-fri-gpu-gar-and-circuit-prover-gpu-gar.yml
if: contains(github.ref_name, 'prover')
with:
setup_keys_id: ${{ needs.setup.outputs.prover_fri_gpu_key_id }}
image_tag_suffix: ${{ needs.setup.outputs.image_tag_suffix }}
protocol_version: ${{ needs.build-push-prover-images.outputs.protocol_version }}