From 8d899f1a534fdcfdc78c7d750c1933e1cfd9a1c4 Mon Sep 17 00:00:00 2001 From: whyour Date: Tue, 19 Sep 2023 00:30:45 +0800 Subject: [PATCH] =?UTF-8?q?=20=E6=9B=B4=E6=96=B0=20workflow?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/build_docker_image.yml | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build_docker_image.yml b/.github/workflows/build_docker_image.yml index 86b00df6021..6de558f346c 100644 --- a/.github/workflows/build_docker_image.yml +++ b/.github/workflows/build_docker_image.yml @@ -6,10 +6,9 @@ on: - 'master' - 'develop' tags: - - 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 + - 'v*' schedule: - # 参考 https://jasonet.co/posts/scheduled-actions/ - - cron: '00 14 * * *' # GMT 15:00 => 北京时间 23:00 + - cron: '00 20 * * *' workflow_dispatch: jobs: @@ -95,7 +94,7 @@ jobs: contents: read steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: pnpm/action-setup@v2 with: version: '8.3.1' @@ -109,13 +108,13 @@ jobs: timezone: Asia/Shanghai - name: Login to DockerHub - uses: docker/login-action@v2 + uses: docker/login-action@v3 with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} - name: Login to GHCR - uses: docker/login-action@v2 + uses: docker/login-action@v3 with: registry: ghcr.io username: ${{ github.repository_owner }} @@ -123,7 +122,7 @@ jobs: - name: Extract metadata (tags, labels) for Docker id: meta - uses: docker/metadata-action@v4 + uses: docker/metadata-action@v5 with: images: | ${{ github.repository }} @@ -143,14 +142,14 @@ jobs: type=semver,pattern={{major}} - name: Set up QEMU - uses: docker/setup-qemu-action@v2 + uses: docker/setup-qemu-action@v3 - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v2 + uses: docker/setup-buildx-action@v3 - name: Build and push id: docker_build - uses: docker/build-push-action@v3 + uses: docker/build-push-action@v5 with: build-args: | MAINTAINER=${{ github.repository_owner }}