Build musl and glibc for amd64 and arm64 through one native package path. Reuse musl outputs for OCI images and OpenWrt installers, and export binaries inside a rootless unshare session. Restore the executable dependency graph into a shared persistent NuGet cache, build managed dependencies once, and run isolated native publishes in parallel. Clean temporary outputs and expired image layers under store locks, retire inactive legacy stores after seven days, and retain two toolchain exports. Add regression coverage for staging, extraction, packaging and cleanup boundaries.
119 lines
3.4 KiB
YAML
119 lines
3.4 KiB
YAML
labels:
|
|
ci: domain-linux-native
|
|
platform: linux/amd64
|
|
|
|
clone:
|
|
- name: git
|
|
image: plugin-git
|
|
settings:
|
|
lfs: false
|
|
# 要拿到 tag 才算得出开发版本号(ci/version.sh:自最近 tag 的提交数)
|
|
tags: true
|
|
|
|
when:
|
|
- event: push
|
|
branch: main
|
|
evaluate: 'CI_COMMIT_MESSAGE contains "[CI]"'
|
|
|
|
# 镜像构建和 verify(后端快速测试)、web-build 并行跑,不再等它们:构建好之后、推送之前由 ci/wait-for-checks.sh 等这两个 workflow 都成功
|
|
# (任何一个失败就不推;提交信息写 [SKIP TESTS] 只跳过后端测试,verify 照样是成功)。机器有 6 个 workflow 槽(WOODPECKER_MAX_WORKFLOWS),三个同时跑放得下。
|
|
|
|
concurrency: 1
|
|
|
|
steps:
|
|
- name: build-linux-amd64-backend
|
|
image: bash
|
|
environment:
|
|
NUGET_PACKAGES: /home/justme/woodpecker/cache/nuget/packages
|
|
ZOT_REGISTRY: registry.oeo.one
|
|
ZOT_USERNAME: justme
|
|
ZOT_SECRET:
|
|
from_secret: zot_secret
|
|
RELEASE_API_URL: https://mo.oeo.one
|
|
RELEASE_SIGNING_KEY:
|
|
from_secret: release_signing_key
|
|
commands:
|
|
- python3 ci/run-with-timeout.py 1800 bash ci/build-dev-image.sh backend
|
|
depends_on: []
|
|
|
|
- name: build-musl-amd64
|
|
image: bash
|
|
environment:
|
|
GITEA_BASE: http://127.0.0.1:3100
|
|
GITEA_TOKEN:
|
|
from_secret: gitea_token
|
|
RELEASE_SIGNING_KEY:
|
|
from_secret: release_signing_key
|
|
commands:
|
|
- python3 ci/run-with-timeout.py 3600 bash ci/build-linux-agent.sh linux-musl-x64
|
|
depends_on: []
|
|
|
|
- name: build-musl-arm64
|
|
image: bash
|
|
environment:
|
|
GITEA_BASE: http://127.0.0.1:3100
|
|
GITEA_TOKEN:
|
|
from_secret: gitea_token
|
|
RELEASE_SIGNING_KEY:
|
|
from_secret: release_signing_key
|
|
commands:
|
|
- python3 ci/run-with-timeout.py 3600 bash ci/build-linux-agent.sh linux-musl-arm64
|
|
depends_on: []
|
|
|
|
- name: build-glibc-amd64
|
|
image: bash
|
|
environment:
|
|
GITEA_BASE: http://127.0.0.1:3100
|
|
GITEA_TOKEN:
|
|
from_secret: gitea_token
|
|
RELEASE_SIGNING_KEY:
|
|
from_secret: release_signing_key
|
|
commands:
|
|
- python3 ci/run-with-timeout.py 3600 bash ci/build-linux-agent.sh linux-x64
|
|
depends_on: []
|
|
|
|
- name: build-glibc-arm64
|
|
image: bash
|
|
environment:
|
|
GITEA_BASE: http://127.0.0.1:3100
|
|
GITEA_TOKEN:
|
|
from_secret: gitea_token
|
|
RELEASE_SIGNING_KEY:
|
|
from_secret: release_signing_key
|
|
commands:
|
|
- python3 ci/run-with-timeout.py 3600 bash ci/build-linux-agent.sh linux-arm64
|
|
depends_on: []
|
|
|
|
- name: publish-agent-images
|
|
image: bash
|
|
environment:
|
|
GITEA_BASE: http://127.0.0.1:3100
|
|
GITEA_TOKEN:
|
|
from_secret: gitea_token
|
|
ZOT_REGISTRY: registry.oeo.one
|
|
ZOT_USERNAME: justme
|
|
ZOT_SECRET:
|
|
from_secret: zot_secret
|
|
RELEASE_API_URL: https://mo.oeo.one
|
|
RELEASE_SIGNING_KEY:
|
|
from_secret: release_signing_key
|
|
commands:
|
|
- python3 ci/run-with-timeout.py 900 bash ci/release-node-images.sh
|
|
depends_on:
|
|
- build-musl-amd64
|
|
- build-musl-arm64
|
|
|
|
- name: backend-e2e-tests
|
|
image: bash
|
|
when:
|
|
- evaluate: 'not (CI_COMMIT_MESSAGE contains "[SKIP TESTS]")'
|
|
environment:
|
|
NUGET_PACKAGES: /home/justme/woodpecker/cache/nuget/packages
|
|
commands:
|
|
- bash ci/verify-backend.sh slow
|
|
depends_on:
|
|
- publish-agent-images
|
|
- build-linux-amd64-backend
|
|
- build-glibc-amd64
|
|
- build-glibc-arm64
|