From 2051651410a72d2e0c822759c0e84cd77c565257 Mon Sep 17 00:00:00 2001 From: Anton Whalley Date: Mon, 30 May 2022 20:04:39 +0100 Subject: [PATCH] fix: refactor manifest creation --- .github/workflows/buildmusl.yaml | 29 ++++++++++++++++++--------- charts/core-dump-handler/Chart.yaml | 30 +++++----------------------- charts/core-dump-handler/values.yaml | 2 +- 3 files changed, 26 insertions(+), 35 deletions(-) diff --git a/.github/workflows/buildmusl.yaml b/.github/workflows/buildmusl.yaml index f6f7ac7..7661ed5 100644 --- a/.github/workflows/buildmusl.yaml +++ b/.github/workflows/buildmusl.yaml @@ -2,14 +2,12 @@ name: Build and Push musl on: push: - branches: - - main tags: - 'v*' env: IMAGE_NAME: core-dump-handler-musl - IMAGE_TAGS: v8.5.0 ${{ github.sha }} + IMAGE_TAGS: ${{ github.sha }} IMAGE_REGISTRY: quay.io IMAGE_NAMESPACE: icdh @@ -26,6 +24,9 @@ jobs: # Checkout push-to-registry action github repository - name: Checkout Push to Registry action uses: actions/checkout@v2 + + - id: tag + run: echo ::set-output name=TAG::${GITHUB_REF#refs/tags/} - name: Install qemu dependency run: | @@ -36,22 +37,32 @@ jobs: uses: redhat-actions/buildah-build@main with: image: ${{ env.IMAGE_NAME }} - tags: ${{ env.IMAGE_TAGS }} + tags: ${{ steps.tag.outputs.TAG }}-linux-${{ matrix.arch }} arch: ${{ matrix.arch }} build-args: ARCH=${{ matrix.arch }} containerfiles: | ./musl.Dockerfile - # Push the image manifest to Quay.io (Image Registry) - name: Push To Quay uses: redhat-actions/push-to-registry@v2 id: push with: image: ${{ steps.build_image.outputs.image }} - tags: ${{ steps.build_image.outputs.tags }} + tags: ${{ steps.tag.outputs.TAG }}-linux-${{ matrix.arch }} registry: ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_NAMESPACE }} username: ${{ secrets.REGISTRY_USER }} password: ${{ secrets.REGISTRY_PASSWORD }} - - - name: Echo outputs + - name: Docker Login + uses: docker/login-action@v1 + with: + username: ${{ secrets.REGISTRY_USER }} + password: ${{ secrets.REGISTRY_PASSWORD }} + registry: quay.io + - name: Build Manifest + id: manifests + continue-on-error: true run: | - echo "${{ toJSON(steps.push.outputs) }}" \ No newline at end of file + docker manifest create \ + ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_NAMESPACE }}/${{env.IMAGE_NAME}}:${{ steps.tag.outputs.TAG }} \ + ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_NAMESPACE }}/${{env.IMAGE_NAME}}:${{ steps.tag.outputs.TAG }}-linux-amd64 \ + ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_NAMESPACE }}/${{env.IMAGE_NAME}}:${{ steps.tag.outputs.TAG }}-linux-arm64 + - run: docker manifest push ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_NAMESPACE }}/${{env.IMAGE_NAME}}:${{ steps.tag.outputs.TAG }} diff --git a/charts/core-dump-handler/Chart.yaml b/charts/core-dump-handler/Chart.yaml index 1d7a620..505f948 100644 --- a/charts/core-dump-handler/Chart.yaml +++ b/charts/core-dump-handler/Chart.yaml @@ -10,9 +10,9 @@ sources: type: application -version: v8.5.0 +version: v8.5.1 -appVersion: "v8.5.0" +appVersion: "v8.5.1" icon: https://raw.githubusercontent.com/No9/core-dump-handler/master/assets/handle-with-care-svgrepo-com.svg @@ -29,34 +29,14 @@ maintainers: annotations: artifacthub.io/changes: | - - kind: added - description: Support for ARM and MUSL Libraries - links: - - name: Github PR - url: https://github.com/IBM/core-dump-handler/pull/93 - kind: fixed - description: Large config output hangs composer + description: MUSL Build fix links: - name: Github Issue - url: https://github.com/No9/libcrio/issues/2 - - kind: added - description: Support Podname in template - links: - - name: Github PR - url: https://github.com/IBM/core-dump-handler/pull/92 - - kind: fixed - description: Loading order of the .env in composer - links: - - name: Github PR - url: https://github.com/IBM/core-dump-handler/pull/91 - - kind: fixed - description: Restrict Security Context Constraints - links: - - name: Github PR - url: https://github.com/IBM/core-dump-handler/pull/90 + url: https://github.com/IBM/core-dump-handler/issues/88 artifacthub.io/images: | - name: core-dump-handler - image: quay.io/icdh/core-dump-handler:v8.5.0 + image: quay.io/icdh/core-dump-handler:v8.5.1 artifacthub.io/license: MIT artifacthub.io/signKey: | fingerprint: BED079E67FD431E45301B1C9949E671B46AC8A34 diff --git a/charts/core-dump-handler/values.yaml b/charts/core-dump-handler/values.yaml index f01c434..98ea1bd 100644 --- a/charts/core-dump-handler/values.yaml +++ b/charts/core-dump-handler/values.yaml @@ -3,7 +3,7 @@ replicaCount: 1 image: registry: quay.io repository: icdh/core-dump-handler - tag: v8.5.0 + tag: v8.5.1 pullPolicy: Always pullSecrets: [] request_mem: "64Mi"