ci(.github/workflows): 拆分 CI 与发布流程。
Docker Release / Check web and api (push) Waiting to run
Docker Release / Resolve release tag (push) Blocked by required conditions
Docker Release / Build and publish all-in-one (push) Blocked by required conditions
Docker Release / Build and publish api (push) Blocked by required conditions
Docker Release / Build and publish web (push) Blocked by required conditions
Docker Release / Build and publish dovecot (push) Blocked by required conditions
Docker Release / Build and publish postfix (push) Blocked by required conditions
Docker Release / Build and publish rspamd (push) Blocked by required conditions
Docker Release / Check web and api (push) Waiting to run
Docker Release / Resolve release tag (push) Blocked by required conditions
Docker Release / Build and publish all-in-one (push) Blocked by required conditions
Docker Release / Build and publish api (push) Blocked by required conditions
Docker Release / Build and publish web (push) Blocked by required conditions
Docker Release / Build and publish dovecot (push) Blocked by required conditions
Docker Release / Build and publish postfix (push) Blocked by required conditions
Docker Release / Build and publish rspamd (push) Blocked by required conditions
- 新增独立的 CI 工作流,覆盖前端检查、构建和后端测试。 - 调整 Docker 工作流为仅负责标签发布与镜像构建。 - 同步优化管理页 Issues 图标颜色。
This commit is contained in:
@@ -0,0 +1,61 @@
|
|||||||
|
name: CI
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths-ignore:
|
||||||
|
- "**/*.md"
|
||||||
|
- "deploy/.env.example"
|
||||||
|
pull_request:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths-ignore:
|
||||||
|
- "**/*.md"
|
||||||
|
- "deploy/.env.example"
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
checks:
|
||||||
|
name: Check web and api
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Setup pnpm
|
||||||
|
uses: pnpm/action-setup@v4
|
||||||
|
with:
|
||||||
|
version: 10.28.2
|
||||||
|
|
||||||
|
- name: Setup Node.js
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: 20
|
||||||
|
cache: pnpm
|
||||||
|
cache-dependency-path: pnpm-lock.yaml
|
||||||
|
|
||||||
|
- name: Install web dependencies
|
||||||
|
run: pnpm install --frozen-lockfile --filter lanqin-email-web...
|
||||||
|
|
||||||
|
- name: Check shadcn/ui usage
|
||||||
|
run: pnpm --dir apps/web run check:shadcn
|
||||||
|
|
||||||
|
- name: Build web
|
||||||
|
run: pnpm --dir apps/web run build
|
||||||
|
|
||||||
|
- name: Setup Go
|
||||||
|
uses: actions/setup-go@v5
|
||||||
|
with:
|
||||||
|
go-version-file: apps/api/go.mod
|
||||||
|
cache-dependency-path: apps/api/go.sum
|
||||||
|
|
||||||
|
- name: Test api
|
||||||
|
working-directory: apps/api
|
||||||
|
run: go test ./...
|
||||||
@@ -1,21 +1,9 @@
|
|||||||
name: CI and Docker
|
name: Docker Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
tags:
|
tags:
|
||||||
- "v*"
|
- "v*"
|
||||||
paths-ignore:
|
|
||||||
- "**/*.md"
|
|
||||||
- "deploy/.env.example"
|
|
||||||
pull_request:
|
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
paths-ignore:
|
|
||||||
- "**/*.md"
|
|
||||||
- "deploy/.env.example"
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
contents: read
|
||||||
@@ -72,7 +60,6 @@ jobs:
|
|||||||
name: Resolve release tag
|
name: Resolve release tag
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: checks
|
needs: checks
|
||||||
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
|
|
||||||
outputs:
|
outputs:
|
||||||
tag: ${{ steps.release.outputs.tag }}
|
tag: ${{ steps.release.outputs.tag }}
|
||||||
version: ${{ steps.release.outputs.version }}
|
version: ${{ steps.release.outputs.version }}
|
||||||
@@ -94,7 +81,6 @@ jobs:
|
|||||||
name: Build and publish ${{ matrix.name }}
|
name: Build and publish ${{ matrix.name }}
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: release
|
needs: release
|
||||||
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
|
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
|
|||||||
@@ -781,7 +781,7 @@ function AboutProjectCard() {
|
|||||||
</Button>
|
</Button>
|
||||||
<Button type="button" variant="outline" className="h-11 justify-start px-4 text-base font-normal" asChild>
|
<Button type="button" variant="outline" className="h-11 justify-start px-4 text-base font-normal" asChild>
|
||||||
<a href={`${projectRepositoryUrl}/issues`} target="_blank" rel="noreferrer">
|
<a href={`${projectRepositoryUrl}/issues`} target="_blank" rel="noreferrer">
|
||||||
<Circle className="h-5 w-5 text-blue-500" />
|
<Circle className="h-5 w-5 text-muted-foreground" />
|
||||||
Issues
|
Issues
|
||||||
</a>
|
</a>
|
||||||
</Button>
|
</Button>
|
||||||
|
|||||||
Reference in New Issue
Block a user