From ec840f05fd44aacd1137c74e6fbd1ed05a17668d Mon Sep 17 00:00:00 2001 From: YkeLit <48484963+YkeLit@users.noreply.github.com> Date: Thu, 25 Jul 2024 17:57:53 +0800 Subject: [PATCH] chore(fe-build-image): update build args (#94) --- fe-build-image/action.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/fe-build-image/action.yml b/fe-build-image/action.yml index f7cf7a7..935467a 100644 --- a/fe-build-image/action.yml +++ b/fe-build-image/action.yml @@ -75,10 +75,10 @@ runs: context: ${{ inputs.context }} file: ${{ inputs.dockerfile }} build-args: | - APP_VSN=${{ steps.meta.outputs.version }} APP_NAME=${{ steps.image.outputs.image_name }} + APP_VERSION=${{ fromJSON(steps.metadata.outputs.json).labels['org.opencontainers.image.version'] }} + APP_REVISION=${{ fromJSON(steps.metadata.outputs.json).labels['org.opencontainers.image.revision'] }} SOURCE_REPO_URL=${{ github.repositoryUrl }} - SOURCE_SHA=${{ github.sha }} ${{ inputs.build_args }} push: true labels: ${{ steps.meta.outputs.labels }} @@ -94,10 +94,10 @@ runs: context: ${{ inputs.context }} file: ${{ inputs.dockerfile }} build-args: | - APP_VSN=${{ steps.meta.outputs.version }} APP_NAME=${{ steps.image.outputs.image_name }} + APP_VERSION=${{ fromJSON(steps.metadata.outputs.json).labels['org.opencontainers.image.version'] }} + APP_REVISION=${{ fromJSON(steps.metadata.outputs.json).labels['org.opencontainers.image.revision'] }} SOURCE_REPO_URL=${{ github.repositoryUrl }} - SOURCE_SHA=${{ github.sha }} ${{ inputs.build_args }} push: true labels: ${{ steps.meta.outputs.labels }} @@ -113,10 +113,10 @@ runs: context: ${{ inputs.context }} file: ${{ inputs.dockerfile }} build-args: | - APP_VSN=${{ steps.meta.outputs.version }} APP_NAME=${{ steps.image.outputs.image_name }} + APP_VERSION=${{ fromJSON(steps.metadata.outputs.json).labels['org.opencontainers.image.version'] }} + APP_REVISION=${{ fromJSON(steps.metadata.outputs.json).labels['org.opencontainers.image.revision'] }} SOURCE_REPO_URL=${{ github.repositoryUrl }} - SOURCE_SHA=${{ github.sha }} ${{ inputs.build_args }} push: true labels: ${{ steps.meta.outputs.labels }}