ci: build Arcane service images on GitHub
Build image / build (push) Canceled after 0s
Build ASR Pipeline / image (push) Canceled after 0s
Build image / build (push) Canceled after 0s
Build Snell DC9 / image (push) Canceled after 0s
Build image / build (push) Canceled after 0s
Build Snell HK / image (push) Canceled after 0s
Build image / build (push) Canceled after 0s
Build WeChat Fulltext / image (push) Canceled after 0s
Build image / build (push) Canceled after 0s
Build ASR Pipeline / image (push) Canceled after 0s
Build image / build (push) Canceled after 0s
Build Snell DC9 / image (push) Canceled after 0s
Build image / build (push) Canceled after 0s
Build Snell HK / image (push) Canceled after 0s
Build image / build (push) Canceled after 0s
Build WeChat Fulltext / image (push) Canceled after 0s
This commit is contained in:
@@ -0,0 +1,56 @@
|
|||||||
|
name: Build image
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
inputs:
|
||||||
|
context:
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
image_name:
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
packages: write
|
||||||
|
concurrency:
|
||||||
|
group: image-${{ inputs.image_name }}-${{ github.ref }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
steps:
|
||||||
|
- name: Check out repository
|
||||||
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||||
|
|
||||||
|
- name: Set up Buildx
|
||||||
|
uses: docker/setup-buildx-action@f87e5991a6d7451dcb8d9637bfbc97413f497069 # v4.4.1
|
||||||
|
|
||||||
|
- name: Log in to GHCR
|
||||||
|
uses: docker/login-action@dbcb813823bdd20940b903addbd779551569679f # v4.6.0
|
||||||
|
with:
|
||||||
|
registry: ghcr.io
|
||||||
|
username: ${{ github.actor }}
|
||||||
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Generate image metadata
|
||||||
|
id: meta
|
||||||
|
uses: docker/metadata-action@dc802804100637a589fabce1cb79ff13a1411302 # v6.2.0
|
||||||
|
with:
|
||||||
|
images: ghcr.io/${{ github.repository_owner }}/${{ inputs.image_name }}
|
||||||
|
tags: |
|
||||||
|
type=raw,value=latest,enable={{is_default_branch}}
|
||||||
|
type=sha,format=long
|
||||||
|
|
||||||
|
- name: Build and push image
|
||||||
|
uses: docker/build-push-action@c3c9e263c25d99ce0380d002d59b67737d91b0dc # v7.4.0
|
||||||
|
with:
|
||||||
|
context: ${{ inputs.context }}
|
||||||
|
platforms: linux/amd64
|
||||||
|
push: true
|
||||||
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
|
cache-from: type=gha,scope=${{ inputs.image_name }}
|
||||||
|
cache-to: type=gha,mode=max,scope=${{ inputs.image_name }}
|
||||||
|
provenance: mode=max
|
||||||
|
sbom: true
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
name: Build ASR Pipeline
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [main]
|
||||||
|
paths:
|
||||||
|
- servers/tools-pve/asr-pipeline/**
|
||||||
|
- .github/workflows/_build-image.yml
|
||||||
|
- .github/workflows/build-asr-pipeline.yml
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
image:
|
||||||
|
uses: ./.github/workflows/_build-image.yml
|
||||||
|
with:
|
||||||
|
context: servers/tools-pve/asr-pipeline
|
||||||
|
image_name: arcane-asr-pipeline
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
name: Build Snell DC9
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [main]
|
||||||
|
paths:
|
||||||
|
- servers/bwh-us-dc9/snell/**
|
||||||
|
- .github/workflows/_build-image.yml
|
||||||
|
- .github/workflows/build-snell-dc9.yml
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
image:
|
||||||
|
uses: ./.github/workflows/_build-image.yml
|
||||||
|
with:
|
||||||
|
context: servers/bwh-us-dc9/snell
|
||||||
|
image_name: arcane-snell-dc9
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
name: Build Snell HK
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [main]
|
||||||
|
paths:
|
||||||
|
- servers/bwh-hk-cmi/snell/**
|
||||||
|
- .github/workflows/_build-image.yml
|
||||||
|
- .github/workflows/build-snell-hk.yml
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
image:
|
||||||
|
uses: ./.github/workflows/_build-image.yml
|
||||||
|
with:
|
||||||
|
context: servers/bwh-hk-cmi/snell
|
||||||
|
image_name: arcane-snell-hk
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
name: Build WeChat Fulltext
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [main]
|
||||||
|
paths:
|
||||||
|
- servers/tools-pve/wechat-fulltext/**
|
||||||
|
- .github/workflows/_build-image.yml
|
||||||
|
- .github/workflows/build-wechat-fulltext.yml
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
image:
|
||||||
|
uses: ./.github/workflows/_build-image.yml
|
||||||
|
with:
|
||||||
|
context: servers/tools-pve/wechat-fulltext
|
||||||
|
image_name: arcane-wechat-fulltext
|
||||||
Reference in New Issue
Block a user