Skip to content

Commit

Permalink
use make update-go-verison to update go version in Dockerfile
Browse files Browse the repository at this point in the history
Signed-off-by: duanmengkk <[email protected]>
  • Loading branch information
duanmengkk committed Mar 15, 2024
1 parent 1371766 commit 8d076da
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/build-image-base.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,15 @@ jobs:
- name: Generating Base Image Tag
id: base_tag
run: |
echo "tag=$(git ls-tree --full-tree HEAD -- ./${{ env.IMAGE_ROOT_PATH }}/${{ env.IMAGE_NAME }} | awk '{ print $3 }')" >> $GITHUB_ENV
echo "::set-output name=tag::$(git ls-tree --full-tree HEAD -- images/baseimage | awk '{ print $3 }')"
# echo "tag=$(git ls-tree --full-tree HEAD -- ./${{ env.IMAGE_ROOT_PATH }}/${{ env.IMAGE_NAME }} | awk '{ print $3 }')" >> $GITHUB_ENV
# check whether we have upload the same base image to online register , if so, we could not build it
- name: Checking if tag already exists
id: tag-in-repositories
shell: bash
run: |
if docker buildx imagetools inspect ${{ env.ONLINE_REGISTER }}/${{ env.IMAGE_REPO }}/${{ env.IMAGE_NAME }}:${{ env.tag }} &>/dev/null; then
if docker buildx imagetools inspect ${{ env.ONLINE_REGISTER }}/${{ env.IMAGE_REPO }}/${{ env.IMAGE_NAME }}:${{ steps.base_tag.outputs.tag }} &>/dev/null; then
echo "exists=true" >> $GITHUB_ENV
echo "the target base image exist , no need to build it "
else
Expand Down Expand Up @@ -117,7 +118,7 @@ jobs:
github-token: ${{ secrets.WELAN_PAT }}
platforms: ${{ env.BUILD_PLATFORM }}
tags: |
${{ env.ONLINE_REGISTER }}/${{ env.IMAGE_REPO }}/${{ env.IMAGE_NAME }}:${{ env.tag }}
${{ env.ONLINE_REGISTER }}/${{ env.IMAGE_REPO }}/${{ env.IMAGE_NAME }}:${{ steps.base_tag.outputs.tag }}
- name: Image Release Digest
if: ${{ env.exists == 'false' }}
Expand All @@ -126,7 +127,7 @@ jobs:
mkdir -p image-digest/
echo "## ${{ env.IMAGE_NAME }}" > image-digest/${{ env.IMAGE_NAME }}.txt
echo "" >> image-digest/${{ env.IMAGE_NAME }}.txt
echo "\`${{ env.ONLINE_REGISTER }}/${{ env.IMAGE_REPO }}/${{ env.IMAGE_NAME }}:${{ env.tag }}@${{ steps.docker_build_release.outputs.digest }}\`" >> image-digest/${{ env.IMAGE_NAME }}.txt
echo "\`${{ env.ONLINE_REGISTER }}/${{ env.IMAGE_REPO }}/${{ env.IMAGE_NAME }}:${{ steps.base_tag.outputs.tag }}@${{ steps.docker_build_release.outputs.digest }}\`" >> image-digest/${{ env.IMAGE_NAME }}.txt
echo "" >> image-digest/${{ env.IMAGE_NAME }}.txt
- name: Upload artifact digests
Expand Down

0 comments on commit 8d076da

Please sign in to comment.