Skip to content

fix: image

fix: image #40

Workflow file for this run

name: deploy
on:
push:
tags: ["v*.*.*-*"]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Log into registry Aliyun Container Registry
uses: docker/login-action@v3
with:
registry: registry.cn-shanghai.aliyuncs.com
username: ${{ secrets.ALI_CR_USERNAME }}
password: ${{ secrets.ALI_CR_PASSWORD }}
- name: Extract mw Docker Metadata
id: mw_meta
uses: docker/metadata-action@v5
with:
images: |
registry.cn-shanghai.aliyuncs.com/prts/mw
ghcr.io/mooncellwiki/mw
tags: |
type=semver,pattern={{raw}}
type=sha
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
file: .github/workflows/mw.Dockerfile
push: true
tags: ${{ steps.mw_meta.outputs.tags }}
labels: ${{ steps.mw_meta.outputs.labels }}
- name: Extract nginx Docker Metadata
id: ng_meta
uses: docker/metadata-action@v5
with:
images: |
registry.cn-shanghai.aliyuncs.com/prts/ng
ghcr.io/mooncellwiki/ng
tags: |
type=semver,pattern={{raw}}
type=sha
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
file: .github/workflows/nginx.Dockerfile
push: true
tags: ${{ steps.ng_meta.outputs.tags }}
labels: ${{ steps.ng_meta.outputs.labels }}
build-args: VERSION=${{ github.ref_name }}
- name: Extract Caddy Docker Metadata
id: caddy_meta
uses: docker/metadata-action@v5
with:
images: |
registry.cn-shanghai.aliyuncs.com/prts/caddy
ghcr.io/mooncellwiki/caddy
tags: |
type=semver,pattern={{raw}}
type=sha
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
file: .github/workflows/caddy.Dockerfile
push: true
tags: ${{ steps.caddy_meta.outputs.tags }}
labels: ${{ steps.caddy_meta.outputs.labels }}
build-args: VERSION=${{ github.ref_name }}