diff --git a/.github/workflows/build_docker_image.yml b/.github/workflows/build_docker_image.yml index 86b00df6..6de558f3 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 }}