Files
The-transit-Project/.github/agents/azure-deploy/scaffold/references/scaffold-schemas.ts
T
Sven laptop 635a130f0b
Build and Push Docker Images / detect-changes (push) Successful in 11s
Build and Push Docker Images / build-auth-api (push) Successful in 1m0s
Build and Push Docker Images / build-employee-api (push) Successful in 1m2s
Build and Push Docker Images / build-transit-api (push) Successful in 1m1s
Build and Push Docker Images / build-error-log-api (push) Successful in 1m5s
Build and Push Docker Images / build-admin-ui (push) Successful in 1m13s
Build and Push Docker Images / build-monitoring-ui (push) Successful in 1m15s
Build and Push Docker Images / deploy-test-node (push) Successful in 3s
──────
### Summary of Changes
  1. Documentation Consolidation:
      • Relocated the docs/ folder and all repository .md files (README.md, DEPLOYMENT.md, DOCKER_README.md,
      DOMAINS_README.md, GETTING_STARTED.md, CI_CD_PORTAINER_GUIDE.md, ADMIN_DEPLOYMENT_SUMMARY.md,
      SECURITY_PRIVATE_FILES.md, handoff.md, azure-project-plan.md, plus service-specific READMEs) into .
      • Updated document links in README.md.
  2. AI Agent Project Map:
      • Created PROJECT_MAP.md in the project root containing complete architecture diagrams, service specs, ports, DB
      schemas, environment variables, and developer workflows.
      • Added PROJECT_MAP.md to .gitignore.
  3. Monitoring UI & Infrastructure Integration:
      • Added monitoring_ui service to docker-compose.yml (port 5175).
      • Configured Gitea workflow docker-build.yml for monitoring_ui builds.
      • Added CORS middleware headers in index.js.
      • Added nginx.conf copy step in Dockerfile.

  ──────
  ### Recommended Commit Message

    docs: consolidate project documentation into monitoring_ui and add agent project map

    - Move all markdown documentation files and docs/ folder into monitoring_ui/docs/
    - Update documentation hub index (monitoring_ui/docs/README.md) with relative paths
    - Generate comprehensive AI agent reference map (PROJECT_MAP.md) in repository root
    - Add PROJECT_MAP.md and monitoring_ui build output/env overrides to .gitignore
    - Integrate monitoring_ui service into docker-compose.yml and Gitea CI workflow
    - Configure CORS handling in employee_api for monitoring dashboard access
    ──────
  ### Alternative Short Commit Message

    refactor(docs): move docs to monitoring_ui and create AI agent PROJECT_MAP.md
2026-09-20 23:33:55 +02:00

116 lines
4.0 KiB
TypeScript

/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See LICENSE.md in the project root for license information.
*--------------------------------------------------------------------------------------------*/
/**
* Scaffold artifact schema — scaffold-manifest.json.
* Read by scaffold refs (validation-and-manifest.md, scaffold-healing-rules.md, iac-generation-rules.md).
*/
// ─── Scaffold healing types ──────────────────────────────────────────────────
export type ScaffoldErrorClassification = "FIXABLE" | "BLOCKING";
export type ScaffoldHealingResult = "fixed" | "still-failing" | "blocked";
export interface ScaffoldHealingError {
check: string;
detail: string;
classification: ScaffoldErrorClassification;
}
export interface ScaffoldHealingFix {
file: string;
change: string;
reason: string;
}
export interface ScaffoldHealingAttempt {
attempt: number;
errors: ScaffoldHealingError[];
fixes: ScaffoldHealingFix[];
result: ScaffoldHealingResult;
/** True when this healing attempt changed the service type or region — requires re-approval */
planLevelChange?: boolean;
/** Original service before the pivot (e.g., "App Service B1") */
originalService?: string;
/** New service after the pivot (e.g., "Container Apps Consumption") */
newService?: string;
}
// ─── scaffold-manifest.json ──────────────────────────────────────────────────
export type SelfReviewRating = "VERIFIED" | "PLAUSIBLE" | "FLAGGED";
export interface ScaffoldFile {
path: string;
type: string;
}
export interface SelfReviewFinding {
layer: string; // "L1" | "L2" | "L3" | "L4"
claim: string;
rating: SelfReviewRating;
detail: string;
}
export type IacFormat = "bicep" | "terraform";
export interface ValidationCheck {
name: string;
passed: boolean;
detail?: string;
}
/**
* Result of Step 11 IaC validation. This is what `ScaffoldManifest.validationResult` holds.
* Distinct from `ConformanceResult` below — do not substitute one for the other.
*/
export interface ValidationResult {
status: "Validated" | "Partial" | "Failed";
checks: ValidationCheck[];
proof?: string;
}
/** One BLOCK failure emitted by scaffold-conformance.{ps1,sh} (Step 3c plan-conformance gate). */
export interface ConformanceFailure {
id: string; // e.g. "TAGS-NO-CAMEL", "NO-PLAINTEXT-SECRET", "DB-TLS-ON"
detail: string;
file: string;
}
/** Result of the deterministic plan-conformance gate (subagent-validate.md Step 3c). */
export interface ConformanceResult {
passed: boolean;
failures: ConformanceFailure[];
/** "script" when scaffold-conformance.{ps1,sh} ran; "manual" when the fallback assertion table was used. */
source: "script" | "manual";
}
export interface ScaffoldManifest {
/** Session id this manifest belongs to. */
sessionId: string;
/** UTC timestamp when scaffold completed. */
scaffoldCompletedUtc: string;
iacFormat: IacFormat;
/** Deployment scope for the generated IaC (deploy preflight branches on this). */
targetScope: "subscription" | "resourceGroup";
files: ScaffoldFile[];
/** Entry-point IaC file, e.g. "infra/main.bicep". */
entryPoint?: string;
/** Parameters file, e.g. "infra/main.parameters.json". */
parametersFile?: string;
/** Exact command the deploy phase runs to provision (read by deploy preflight). */
deployCommand: string;
/** Container Apps two-phase (infra, then image) wiring, when applicable. */
twoPhaseWiring?: boolean;
/** Ordered phase-2 steps (e.g. image build/push) for two-phase deploys. */
phase2Steps?: readonly string[];
selfReview: {
findings: SelfReviewFinding[];
healingAttempts?: readonly ScaffoldHealingAttempt[];
};
validationResult?: ValidationResult;
conformance?: ConformanceResult;
}