Skip to content

Commit 532e89c

Browse files
committed
fix: ci to use the right tag pattern and push to the correct place with the right context
1 parent c41641a commit 532e89c

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

.github/workflows/build_container.yaml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ name: Create and publish a Skyhook Package
55
on:
66
push:
77
tags:
8+
- '**'
89

910

1011
# Defines two custom environment variables for the workflow. These are used for the Container registry domain, and a name for the Docker image that this workflow builds.
@@ -40,7 +41,7 @@ jobs:
4041
id: meta
4142
uses: docker/metadata-action@9ec57ed1fcdbf14dcef7dfbe97b2010124a938b7
4243
with:
43-
images: ${{ env.REGISTRY }}/skyhook-packages/${{ env.PACKAGE_NAME }}
44+
images: ${{ env.REGISTRY }}/${{env.IMAGE_NAME}}/${{ env.PACKAGE_NAME }}
4445
tags: |
4546
type=match,pattern=\d.\d.\d
4647
# This step uses the `docker/build-push-action` action to build the image, based on your repository's `Dockerfile`. If the build succeeds, it pushes the image to GitHub Packages.
@@ -50,17 +51,17 @@ jobs:
5051
id: push
5152
uses: docker/build-push-action@f2a1d5e99d037542a71f64918e516c093c6f3fc4
5253
with:
53-
context: .
54+
context: ${{ env.PACKAGE_NAME }}
5455
push: true
5556
tags: ${{ steps.meta.outputs.tags }}
5657
labels: ${{ steps.meta.outputs.labels }}
57-
platform: linux/amd64,linux/arm64
58+
#platforms: linux/amd64,linux/arm64
5859

5960
# This step generates an artifact attestation for the image, which is an unforgeable statement about where and how it was built. It increases supply chain security for people who consume the image. For more information, see [AUTOTITLE](/actions/security-guides/using-artifact-attestations-to-establish-provenance-for-builds).
6061
- name: Generate artifact attestation
6162
uses: actions/attest-build-provenance@v2
6263
with:
63-
subject-name: ${{ env.REGISTRY }}/skyhook-packages/${{ env.PACKAGE_NAME }}
64+
subject-name: ${{ env.REGISTRY }}/${{env.IMAGE_NAME}}/${{ env.PACKAGE_NAME }}
6465
subject-digest: ${{ steps.push.outputs.digest }}
6566
push-to-registry: true
6667

0 commit comments

Comments
 (0)