Skip to content

Commit 2112544

Browse files
committed
fixed the pipeline
1 parent 02897c5 commit 2112544

File tree

1 file changed

+25
-28
lines changed

1 file changed

+25
-28
lines changed

.github/workflows/release.yaml

Lines changed: 25 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
name: Release
22

33
on:
4-
pull_request:
5-
branches:
6-
- main
74
release:
85
types: [created]
96

@@ -12,7 +9,7 @@ permissions:
129

1310
jobs:
1411
publish-image:
15-
#if: startsWith(github.ref, 'refs/tags/v') == true
12+
if: startsWith(github.ref, 'refs/tags/v') == true
1613
runs-on: ubuntu-22.04
1714

1815
permissions:
@@ -46,53 +43,53 @@ jobs:
4643
with:
4744
registry: ghcr.io
4845
username: loft-sh
49-
#password: ${{ secrets.GITHUB_TOKEN }}
50-
# - name: Build and push the hooks
51-
# uses: docker/build-push-action@v4
52-
# working-directory: ./examples/hooks
53-
# id: docker_build
54-
# with:
55-
# file: Dockerfile
56-
# platforms: linux/amd64,linux/arm64
57-
# push: true
58-
# tags: "ghcr.io/loft-sh/vcluster-example-hooks:${{steps.get_version.outputs.release_version}}"
59-
# labels: ${{ steps.docker_meta.outputs.labels }}
46+
password: ${{ secrets.GITHUB_TOKEN }}
47+
- name: Build and push the hooks
48+
uses: docker/build-push-action@v4
49+
id: docker_build_hooks
50+
with:
51+
file: ./examples/hooks/Dockerfile
52+
platforms: linux/amd64,linux/arm64
53+
push: true
54+
tags: "ghcr.io/loft-sh/vcluster-example-hooks:${{steps.get_version.outputs.release_version}}"
55+
labels: ${{ steps.docker_meta.outputs.labels }}
56+
context: ./examples/hooks
6057
- name: Images digests for
61-
run: echo ${{ steps.docker_build.outputs.digest }}
58+
run: echo ${{ steps.docker_build_hooks.outputs.digest }}
6259
- name: Build and push the bootstrap
63-
id: docker_build
64-
working-directory: ./examples/bootstrap-with-deployment
6560
uses: docker/build-push-action@v4
61+
id: docker_build_bootstrap
6662
with:
67-
file: Dockerfile
63+
file: ./examples/bootstrap-with-deployment/Dockerfile
64+
context: ./examples/bootstrap-with-deployment
6865
platforms: linux/amd64,linux/arm64
6966
push: true
7067
tags: "ghcr.io/loft-sh/vcluster-example-bootstrap-bootstrap-with-deployment:${{steps.get_version.outputs.release_version}}"
7168
labels: ${{ steps.docker_meta.outputs.labels }}
7269
- name: Images digests for bootstrap
73-
run: echo ${{ steps.docker_build.outputs.digest }}
70+
run: echo ${{ steps.docker_build_bootstrap.outputs.digest }}
7471
- name: Build and push import secret
75-
working-directory: ./examples/import-secrets
76-
id: docker_build
7772
uses: docker/build-push-action@v4
73+
id: docker_build_import_secret
7874
with:
79-
file: Dockerfile
75+
file: ./examples/import-secrets/Dockerfile
76+
context: ./examples/import-secrets
8077
platforms: linux/amd64,linux/arm64
8178
push: true
8279
tags: "ghcr.io/loft-sh/vcluster-example-import-secrets:${{steps.get_version.outputs.release_version}}"
8380
labels: ${{ steps.docker_meta.outputs.labels }}
8481
- name: Images digests for import secret
85-
run: echo ${{ steps.docker_build.outputs.digest }}
82+
run: echo ${{ steps.docker_build_import_secret.outputs.digest }}
8683
- name: Build and push crd sync
87-
working-directory: ./examples/crd-sync
88-
id: docker_build
8984
uses: docker/build-push-action@v4
85+
id: docker_build_crd_sync
9086
with:
91-
file: Dockerfile
87+
file: ./examples/crd-sync/Dockerfile
88+
context: ./examples/crd-sync/
9289
platforms: linux/amd64,linux/arm64
9390
push: true
9491
tags: "ghcr.io/loft-sh/vcluster-example-crd-sync:${{steps.get_version.outputs.release_version}}"
9592
labels: ${{ steps.docker_meta.outputs.labels }}
9693
- name: Images digests for crd sync
97-
run: echo ${{ steps.docker_build.outputs.digest }}
94+
run: echo ${{ steps.docker_build_crd_sync.outputs.digest }}
9895

0 commit comments

Comments
 (0)