docs: standardize gitea pac cicd architecture

This commit is contained in:
Codex
2026-07-06 15:32:08 +00:00
parent a22ea24ded
commit 79a35183aa
16 changed files with 180 additions and 63 deletions
+20 -8
View File
@@ -1,5 +1,5 @@
// SPEC: GH-1548 Gitea mirror/Actions visibility and controlled Docker builder POC.
// Responsibility: read-only YAML-first plan/status for the proposed CI/CD governance split.
// SPEC: GH-1548/GH-1560 archived Gitea Actions POC.
// Responsibility: read-only historical plan/status for the retired Gitea Actions POC.
import { existsSync, readFileSync } from "node:fs";
import { isAbsolute } from "node:path";
import { rootPath, type UniDeskConfig } from "./config";
@@ -29,6 +29,8 @@ interface LoadedPoc {
export function cicdGiteaActionsPocHelp(): unknown {
return {
command: "cicd gitea-actions-poc plan|status",
archived: true,
replacement: "bun scripts/cli.ts platform-infra pipelines-as-code status --target JD01",
output: "text by default; use --json, --raw, or -o json|yaml for machine output",
usage: [
"bun scripts/cli.ts cicd gitea-actions-poc plan",
@@ -36,8 +38,8 @@ export function cicdGiteaActionsPocHelp(): unknown {
"bun scripts/cli.ts cicd gitea-actions-poc plan --target agentrun-jd01-v02",
],
config: DEFAULT_CONFIG_PATH,
issue: "https://github.com/pikasTech/unidesk/issues/1548",
description: "Read-only P1/P2 plan for replacing branch-follower responsibilities with Gitea mirror, Gitea Actions visibility, controlled Docker/BuildKit builder plane, existing Tekton, existing Argo CD, and bounded UniDesk status while preserving env reuse.",
issue: "https://github.com/pikasTech/unidesk/issues/1560",
description: "Archived read-only POC. JD01 production CI/CD uses Gitea mirror -> Pipelines-as-Code -> Tekton -> Argo/k8s runtime; do not use Gitea Actions or act_runner as a fallback.",
};
}
@@ -385,6 +387,9 @@ function renderPlanHuman(payload: Record<string, unknown>): string {
return [
`CI/CD GITEA-ACTIONS POC PLAN (${payload.ok === false ? "blocked" : "ok"})`,
"",
"ARCHIVE NOTICE",
"This is historical GH-1548 POC material. Current JD01 CI/CD closeout is platform-infra pipelines-as-code status/history; Gitea Actions and act_runner are not fallback paths.",
"",
table(["TARGET", "SOURCE", "NODE/LANE", "BASELINE", "SNAPSHOT", "TEKTON", "ARGO", "RUNTIME"], arrayRecords(payload.targets).map((target) => [
target.id,
`${target.repository ?? "-"}@${target.branch ?? "-"}`,
@@ -428,8 +433,10 @@ function renderPlanHuman(payload: Record<string, unknown>): string {
errors.length === 0 ? "" : `\nERRORS\n${errors.map((item) => `- ${item}`).join("\n")}`,
"",
"NEXT",
`status: ${next?.status ?? "-"}`,
`existing-follower: ${next?.existingFollowerStatus ?? "-"}`,
`pac-status: bun scripts/cli.ts platform-infra pipelines-as-code status --target JD01`,
`pac-history: bun scripts/cli.ts platform-infra pipelines-as-code history --target JD01 --limit 10`,
`archived-status: ${next?.status ?? "-"}`,
`legacy-follower: ${next?.existingFollowerStatus ?? "-"}`,
`issue: ${next?.pocIssue ?? payload.issue ?? "-"}`,
"",
].filter((line) => line !== "").join("\n");
@@ -443,6 +450,9 @@ function renderStatusHuman(payload: Record<string, unknown>): string {
return [
`CI/CD GITEA-ACTIONS POC STATUS (${payload.ok === false ? "blocked" : "declared-only"})`,
"",
"ARCHIVE NOTICE",
"This command reads an archived POC spec only. Use platform-infra pipelines-as-code status/history for current JD01 CI/CD evidence.",
"",
`statusSource=${payload.statusSource ?? "-"} mode=${payload.statusMode ?? "-"}`,
`replacement=${migration?.replacementTarget ?? "-"} branchFollower=${branchFollower?.status ?? "-"}:${branchFollower?.mode ?? "-"}`,
"",
@@ -460,8 +470,10 @@ function renderStatusHuman(payload: Record<string, unknown>): string {
errors.length === 0 ? "" : `\nERRORS\n${errors.map((item) => `- ${item}`).join("\n")}`,
"",
"NEXT",
`plan: ${next?.plan ?? "-"}`,
`existing-follower: ${next?.existingFollowerStatus ?? "-"}`,
`pac-status: bun scripts/cli.ts platform-infra pipelines-as-code status --target JD01`,
`pac-history: bun scripts/cli.ts platform-infra pipelines-as-code history --target JD01 --limit 10`,
`archived-plan: ${next?.plan ?? "-"}`,
`legacy-follower: ${next?.existingFollowerStatus ?? "-"}`,
"",
].filter((line) => line !== "").join("\n");
}