2.0 KiB
2.0 KiB
CI Template Generator CLI Command (stella ci init)
Module
Cli
Status
IMPLEMENTED
Description
CLI command stella ci init generating ready-to-run CI pipeline templates for GitHub Actions, GitLab CI, and Gitea. Supports gate/scan/verify/full template types, offline-friendly bundles with pinned scanner image digests, and template validation via stella ci validate.
Implementation Details
- Command Group:
src/Cli/StellaOps.Cli/Commands/CiCommandGroup.cs--CiCommandGroup(public static class) - CI Templates:
src/Cli/StellaOps.Cli/Commands/CiTemplates.cs-- template definitions and generation logic - Sprint: SPRINT_20251229_015_CLI_ci_template_generator
- Commands:
stella ci init-- generate CI pipeline templates. Options:--provider github|gitlab|gitea,--type gate|scan|verify|full,--output <path>stella ci validate-- validate generated CI templates for correctness
- Template types: gate (policy gate only), scan (scan + gate), verify (full verification), full (complete pipeline)
- Offline support: Templates include pinned scanner image digests for air-gapped environments
E2E Test Plan
- Run
stella ci init --provider github --type full --output .github/workflows/and verify GitHub Actions workflow file created - Run
stella ci init --provider gitlab --type scanand verify .gitlab-ci.yml created with scan stage - Run
stella ci init --provider gitea --type gateand verify Gitea workflow created with gate stage - Run
stella ci init --type verifyand verify verification pipeline template generated - Run
stella ci validate .github/workflows/stella.ymland verify template validation passes - Verify generated templates contain pinned scanner image digests (sha256 references)
- Verify templates are functional when run in their respective CI environments
- Verify offline-friendly bundle mode generates self-contained templates
- Run with invalid
--providerand verify helpful error message