From d190d4b92f83a5a691bb1687b0b7a1f35f639f7a Mon Sep 17 00:00:00 2001 From: Huabing Zhao Date: Thu, 19 Dec 2024 03:43:47 +0000 Subject: [PATCH] push image Signed-off-by: Huabing Zhao --- .github/workflow/build.yaml | 15 --------------- .github/workflows/build.yaml | 25 +++++++++++++++++++++++++ 2 files changed, 25 insertions(+), 15 deletions(-) delete mode 100644 .github/workflow/build.yaml create mode 100644 .github/workflows/build.yaml diff --git a/.github/workflow/build.yaml b/.github/workflow/build.yaml deleted file mode 100644 index 25224d2..0000000 --- a/.github/workflow/build.yaml +++ /dev/null @@ -1,15 +0,0 @@ -name: Build and Push Docker Image -on: - push: - branches: - - main -jobs: - docker_images: - name: Build and Push Docker Image - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: docker/setup-buildx-action@v3 - - name: Build and Push Image - run: | - make push-image diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000..aa224f3 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,25 @@ +name: Build and Push Docker Image +on: + push: + branches: + - main +jobs: + build-and-push-image: + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + attestations: write + id-token: write + steps: + - name: Checkout repository + uses: actions/checkout@v4 + - name: Log in to the Container registry + uses: docker/login-action@65b78e6e13532edd9afa3aa52ac7964289d1a9c1 + with: + registry: ${{ env.REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Build and Push Image + run: | + make push-image