From 56fa760175a24166d4024f2a0c0e73f7c609a7c1 Mon Sep 17 00:00:00 2001 From: ClasWen Date: Thu, 17 Oct 2024 19:40:25 +0800 Subject: [PATCH] update action --- .github/workflows/main.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2af6e2b..f3def13 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -21,8 +21,7 @@ jobs: steps: - uses: actions/checkout@v4 - - name: Build container - uses: docker/build-push-action@v6 + - uses: docker/build-push-action@v6 with: context: . file: ./Dockerfile @@ -33,28 +32,29 @@ jobs: build-and-push: runs-on: ubuntu-latest + needs: build steps: - uses: actions/checkout@v4 - - name: Login DockerHub + - name: Login uses: docker/login-action@v2 with: registry: ${{ env.REGISTRY }} username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - - name: Build and Push to DockerHub + - name: Build and Push uses: docker/build-push-action@v6 with: context: . file: ./Dockerfile - no-cache: true + no-cache: false push: true platforms: linux/amd64 tags: | ${{ env.IMAGE_NAME_FULL }}:${{ github.ref_name }} - - name: ssh pipelines + - name: Deploy uses: appleboy/ssh-action@v1.0.0 env: BRANCH_NAME: ${{ github.ref_name }}