mirror of
https://github.com/EstrellaXD/Auto_Bangumi.git
synced 2026-02-03 02:04:06 +08:00
change: update workflows, push docker image to ghcr.io
This commit is contained in:
27
.github/workflows/dev-latest.yml
vendored
27
.github/workflows/dev-latest.yml
vendored
@@ -1,4 +1,4 @@
|
||||
name: Deploy To Dockerhub(dev)
|
||||
name: Build Docker(dev)
|
||||
|
||||
on:
|
||||
push:
|
||||
@@ -36,20 +36,27 @@ jobs:
|
||||
working-directory: ./src
|
||||
run: |
|
||||
echo "VERSION = '$GITHUB_REF_NAME'" > module/__version__.py
|
||||
-
|
||||
name: Set up QEMU
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v2
|
||||
-
|
||||
name: Set up Docker Buildx
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
-
|
||||
name: Login to Docker Hub
|
||||
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_HUB_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
|
||||
-
|
||||
name: Build and push
|
||||
|
||||
- name: Login to ghcr.io
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ secrets.GITHUB_USERNAME }}
|
||||
password: ${{ secrets.ACCESS_TOKEN }}
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v3
|
||||
with:
|
||||
context: .
|
||||
@@ -57,6 +64,8 @@ jobs:
|
||||
tags: |
|
||||
estrellaxd/auto_bangumi:dev-latest
|
||||
estrellaxd/auto_bangumi:${{ github.ref_name }}
|
||||
ghcr.io/estrellaxd/auto_bangumi:dev-latest
|
||||
ghcr.io/estrellaxd/auto_bangumi:${{ github.ref_name }}
|
||||
file: Dockerfile
|
||||
|
||||
generate_release:
|
||||
|
||||
16
.github/workflows/docker.yml
vendored
16
.github/workflows/docker.yml
vendored
@@ -1,4 +1,4 @@
|
||||
name: Build(Docker)
|
||||
name: Build Docker
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
@@ -61,6 +61,14 @@ jobs:
|
||||
username: ${{ secrets.DOCKER_HUB_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
|
||||
|
||||
- name: Login to ghcr.io
|
||||
if: ${{ github.event_name == 'push' }}
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.ACCESS_TOKEN }}
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v4
|
||||
with:
|
||||
@@ -68,7 +76,9 @@ jobs:
|
||||
builder: ${{ steps.buildx.output.name }}
|
||||
platforms: linux/amd64,linux/arm64,linux/arm
|
||||
push: ${{ github.event_name == 'push' }}
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
tags: |
|
||||
docker.io/estrellaxd/auto_bangumi:${{ steps.meta.outputs.tags }}
|
||||
ghcr.io/estrellaxd/auto_bangumi:${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
cache-from: type=gha, scope=${{ github.workflow }}
|
||||
cache-to: type=gha, scope=${{ github.workflow }}
|
||||
cache-to: type=gha, scope=${{ github.workflow }}
|
||||
|
||||
Submodule docs/wiki updated: a49828bf9c...9dc9f4f4e3
Reference in New Issue
Block a user