Skip to content

Commit 53d7e94

Browse files
committed
fix(ci): copy shared build scripts before docker build
The CI workflows use docker/build-push-action directly (not build-image.sh), so shared scripts must be copied into each service's shared/ directory before building. Also update REUSE.toml for the renamed kms pinned-packages file, and remove the obsolete .GIT_REV file creation from kms workflows (now handled via Dockerfile ARG).
1 parent 8146546 commit 53d7e94

5 files changed

Lines changed: 25 additions & 5 deletions

File tree

.github/workflows/docker-build-check.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,10 @@ jobs:
1919
- name: Set up Docker Buildx
2020
uses: docker/setup-buildx-action@v3
2121

22-
- name: Write GIT_REV
23-
run: git rev-parse HEAD > kms/dstack-app/builder/.GIT_REV
22+
- name: Copy shared build scripts
23+
run: |
24+
cp build/shared/pin-packages.sh kms/dstack-app/builder/shared/
25+
cp build/shared/config-qemu.sh kms/dstack-app/builder/shared/
2426
2527
- name: Build KMS Docker image
2628
uses: docker/build-push-action@v5
@@ -47,6 +49,9 @@ jobs:
4749
- name: Set up Docker Buildx
4850
uses: docker/setup-buildx-action@v3
4951

52+
- name: Copy shared build scripts
53+
run: cp build/shared/pin-packages.sh gateway/dstack-app/builder/shared/
54+
5055
- name: Build Gateway Docker image
5156
uses: docker/build-push-action@v5
5257
with:
@@ -65,6 +70,11 @@ jobs:
6570
- name: Set up Docker Buildx
6671
uses: docker/setup-buildx-action@v3
6772

73+
- name: Copy shared build scripts
74+
run: |
75+
cp build/shared/pin-packages.sh verifier/builder/shared/
76+
cp build/shared/config-qemu.sh verifier/builder/shared/
77+
6878
- name: Build Verifier Docker image
6979
uses: docker/build-push-action@v5
7080
with:

.github/workflows/gateway-release.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ jobs:
3838
- name: Set up Docker Buildx
3939
uses: docker/setup-buildx-action@v3
4040

41+
- name: Copy shared build scripts
42+
run: cp build/shared/pin-packages.sh gateway/dstack-app/builder/shared/
43+
4144
- name: Get Git commit timestamps
4245
run: |
4346
echo "TIMESTAMP=$(git log -1 --pretty=%ct)" >> $GITHUB_ENV

.github/workflows/kms-release.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,10 @@ jobs:
3838
- name: Set up Docker Buildx
3939
uses: docker/setup-buildx-action@v3
4040

41-
- name: Write GIT_REV
42-
run: git rev-parse HEAD > kms/dstack-app/builder/.GIT_REV
41+
- name: Copy shared build scripts
42+
run: |
43+
cp build/shared/pin-packages.sh kms/dstack-app/builder/shared/
44+
cp build/shared/config-qemu.sh kms/dstack-app/builder/shared/
4345
4446
- name: Get Git commit timestamps
4547
run: |

.github/workflows/verifier-release.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@ jobs:
3737
- name: Set up Docker Buildx
3838
uses: docker/setup-buildx-action@v3
3939

40+
- name: Copy shared build scripts
41+
run: |
42+
cp build/shared/pin-packages.sh verifier/builder/shared/
43+
cp build/shared/config-qemu.sh verifier/builder/shared/
44+
4045
- name: Get Git commit timestamps
4146
run: |
4247
echo "TIMESTAMP=$(git log -1 --pretty=%ct)" >> $GITHUB_ENV

REUSE.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ path = [
3232
"sdk/simulator/*.json",
3333
"sdk/go/go.sum",
3434
"sdk/go/ratls/go.sum",
35-
"kms/dstack-app/builder/shared/kms-pinned-packages.txt",
35+
"kms/dstack-app/builder/shared/builder-pinned-packages.txt",
3636
"kms/dstack-app/builder/shared/qemu-pinned-packages.txt",
3737
"gateway/dstack-app/builder/shared/builder-pinned-packages.txt",
3838
"gateway/dstack-app/builder/shared/pinned-packages.txt",

0 commit comments

Comments
 (0)