Commit Graph
26 Commits
Author SHA1 Message Date
james.maesandCodex 21517b25e7 fix: refresh generated JVM runtime packages on every build
Co-Authored-By: Codex <noreply@openai.com>
Signed-off-by: James Maes <james@kof22.com>
2026-10-19 07:50:52 -05:00
james.maesandClaude Opus 5.5 69898922be fix: push supplemental images on release builds again
CircleCI renders the boolean push parameter as 1/0 in the step
environment, but build_push_supplemental.sh only pushed when
PUSH_IMAGES was the string "true". Since 0.3.5 every release build
built and scanned supplemental images and never pushed them, so
deployments referencing them hit ImagePullBackOff (kof22 0.1.75).

PUSH_IMAGES now accepts true/1/yes/on and false/0/no/off/empty; unset
still means push, and an unrecognised value fails before any build.
Tests cover release-mode pushes (1, true, TRUE) of every supplemental
image, PR-mode non-pushes (0, false, empty), and the invalid value.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: James Maes <james@kof22.com>
2026-10-13 17:05:34 -05:00
james.maesandClaude Opus 5.5 b09ced056f feat: scan container images in PR pipelines
New munitor/docker_scan job (image-scan) in the pr-checks workflow of
java-webapp, gradle-webapp, node-api and node-webapp: builds the app
image and every supplemental image, runs the same Trivy 0.69.3
HIGH/CRITICAL --exit-code 1 scan as the release pipeline (same
.trivyignore), stores the JSON results, and never pushes.
build_push_supplemental gains push (default true, unchanged behavior).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 14:18:41 -05:00
james.maesandClaude Opus 5.5 d7960161fb test: cover signed API commits and head-refresh retries in update_cd_repo
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: James Maes <james@kof22.com>
2026-10-12 06:02:52 -05:00
james.maesandClaude Opus 5.5 57cb7a2aca fix: atomic release versions and immutable image tags
Two main merges built minutes apart both computed the same GitVersion
version. The later pipeline overwrote the image tag in GHCR, github-release
tagged whatever main pointed at (--target main), and the GitOps bump was a
no-op, so production ran an image without the later merge (Website-Backend
0.1.24 and 0.1.32).

- allocate_version: on main, reserve vX.Y.Z by creating the git tag through
  the GitHub refs API (create-if-absent). On conflict with another commit,
  take the next patch; reruns of the same commit reuse their tag. Existing
  tags are never moved. Runs in mvn/gradle/node build-and-test before the
  version is baked into artifacts.
- guard_image_tags: refuse to push a main or supplemental version tag that
  already exists for a different commit (org.opencontainers.image.revision
  label, now set on every build); fail closed on registry errors.
- update_cd_repo: verify vX.Y.Z belongs to this commit before bumping the
  GitOps repo; record the source commit in the GitOps commit message.
- github_release: target CIRCLE_SHA1 instead of main and refuse when the tag
  points elsewhere.
- Generator: render cd_path only when cd.path is set, so manifests pinned to
  orb versions predating the parameter (website develop branches, Concilium,
  makers4) stop failing with "Unexpected argument(s): cd_path".

Tests: tests/test_allocate_version.sh (incl. 8 concurrent allocators against
an atomic fake refs API) and tests/test_release_guards.sh.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 13:56:58 -05:00
James MaesandGPT-6 ae7d93328f fix(#18): unblock website release CI
Closes #18

Co-Authored-By: GPT-6 <codex@openai.com>
Signed-off-by: James Maes <jmaes@dmdbrands.com>
2026-10-10 15:06:49 -05:00
james.maes 9c487cfa04 fix(#14): use distroless debian13 runtime for node-webapp
debian12 ships libssl3 3.0.18 with open HIGH/CRITICAL CVEs that fail the Trivy gate; debian13 scans clean.

Closes #14
2026-09-23 17:51:08 -05:00
James Maes 4b11b3acc8 feat(#9): support consolidated GitOps write-back 2026-07-12 05:39:14 -05:00
James Maes 894a550312 fix: preserve node-webapp Dockerfiles
Add an opt-in repository Dockerfile path while retaining generated images by default. Closes #7
2026-07-11 13:42:35 -05:00
james.maes e408693ff5 feat: add obsidian-plugin pipeline type with GitHub Release artifacts
New pipeline type for Obsidian plugins: builds with esbuild, runs
quality gates, and publishes main.js/manifest.json/styles.css to
GitHub Releases. Extends github_release job with release_artifacts
parameter for artifact uploads. 616 tests passing.
2026-04-16 16:37:07 -05:00
james.maes f560062cc3 test: add pnpm Dockerfile generation tests 2026-03-27 15:39:28 -05:00
james.maes c795fbdc12 test: add pnpm fixture and tests for package manager support 2026-03-27 15:11:41 -05:00
james.maes 5550411187 refactor: update tests and docs for node_* rename 2026-03-27 11:54:11 -05:00
james.maes af150158ab feat: add gradle-webapp pipeline type (#2)
* feat: add gradle-webapp pipeline type

Add full Gradle build support mirroring the existing Maven pipeline.
New commands, scripts, jobs, and templates for Gradle projects with
multi-module JaCoCo aggregation, graceful code quality plugin detection,
and shadow JAR discovery via configurable server_module field.

* fix: extract inline test collection to included script

Move the multi-line mkdir/find command into
collect_gradle_test_results.sh to satisfy RC009 orb review
(commands >64 chars must use include syntax).

* fix: embed gradle templates in packed orb scripts

Add gradle-webapp.yml.tpl and gradle-webapp-deploy.yml.tpl to the
pack_generate_config.sh template/partial embed loops so they are
available at runtime when the orb executes on CircleCI.

* fix: improve gradle_jacoco.sh diagnostics and error messaging

Add directory listing of JaCoCo report output before CSV search to
help diagnose missing reports. Improve error message with exact
build.gradle.kts snippet needed to enable CSV report format.
2026-03-22 18:36:53 -05:00
james.maes 5f708237a7 test: validate all external download URLs are reachable
Adds curl HEAD checks for every pinned binary version (Trivy, gh,
gitleaks, kube-linter, terragrunt, yq, kustomize, kubesec, OpenTofu,
sonar-scanner). Also bumps install_tfsec.sh Trivy to 0.69.3.
2026-03-15 15:21:03 -05:00
james.maes 9bc3bcefbd fix: pass supplemental_images param through update_cd_repo job
The job definition was missing the supplemental_images parameter,
so CircleCI silently dropped it even though the template and command
both had it. Added parameter declaration and forwarding, plus
functional upsert tests.
2026-03-08 09:11:03 -05:00
james.maes becc94fa1d test: assert supplemental_images JSON is single-line
Multiline JSON breaks when injected into YAML template parameters.
Add assertion to prevent regression.
2026-03-07 16:42:36 -06:00
james.maesandClaude Opus 4.6 1f829edc81 feat: add supplemental Docker image support for sidecar containers
Build, Trivy-scan, and push N additional images (e.g. Liquibase migrations)
alongside the main app image via supplemental_images config in .munitor.yml.
Supports auto-generated Dockerfiles from base+copy or user-provided Dockerfiles,
and updates CD repos with all image tags atomically.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-07 13:49:16 -06:00
james.maesandClaude Opus 4.6 9247dcc82a feat: add argocd-apps pipeline type for app-of-apps repos
Adds a new pipeline type for ArgoCD app-of-apps repositories that use
environment directories (envs/) instead of the standard base/overlays/
kustomize layout. Makes kustomize_validate configurable with overlay_dir
parameter and conditional base build skip.

- Add KUSTOMIZE_OVERLAY_DIR env var and overlay_dir parameter to
  kustomize_validate command/job
- Skip base build when base_path is empty string
- Use unset-only default (-) for KUSTOMIZE_BASE_PATH so "" is honored
- Use explicit null check for base_path in extract_munitor_vars (yq //
  treats "" as falsy)
- Pipeline-aware yamllint_paths defaults for argocd-apps
- New template, example, fixtures, and tests

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-28 16:29:27 -06:00
james.maesandClaude Opus 4.6 c1b33b7342 fix: pass complete RDBMS env vars to health_check PostgreSQL sidecar
LiquibaseRunner.getDatabaseConnectionInfo() requires all six RDBMS_*
env vars. Missing VENDOR/DATABASE_NAME/USERNAME/PASSWORD caused
NumberFormatException on startup.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-27 15:10:21 -06:00
james.maesandClaude Opus 4.6 25c4682cb7 feat: replace SDKMAN with cimg/openjdk executor and Adoptium APT
Add a new `java` Docker executor using cimg/openjdk images so 6 Java
jobs (build, code-quality, coverage, e2e, sbom, sonar) get pre-installed
Java/Maven with zero download overhead.  Jobs that must stay on the
machine executor (security_scan) now install Java via the Adoptium APT
repository instead of SDKMAN, eliminating an unreliable external
dependency.  Also fix node-webapp Dockerfile tests to match the
auto-generation behavior.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-27 14:31:50 -06:00
james.maesandClaude Opus 4.6 a66937a52a feat: add node-webapp pipeline type for user-provided Dockerfile builds
Node.js webapps have too much build variety for auto-generated Dockerfiles.
The node-webapp pipeline reuses all npm_* jobs from node-api but requires
a user-provided Dockerfile and adds package_manager config support.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21 18:25:34 -06:00
james.maesandClaude Opus 4.6 e06f31c39f fix: use kof22 CircleCI namespace for orb publishing
The CircleCI orb namespace is kof22, not KofTwentyTwo. Update orb slug
from KofTwentyTwo/munitor to kof22/munitor across CI config, scripts,
examples, tests, and docs.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21 15:41:32 -06:00
james.maesandClaude Opus 4.6 325f8204a0 refactor: rename all internal faber/FABER references to munitor/MUNITOR
Rename files, variables, functions, container names, temp paths,
and config file names to complete the migration to the Munitor
namespace. Regenerate packed scripts. All 362 tests pass.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21 15:21:36 -06:00
james.maes 60411297c2 feat: rebrand orb for KofTwentyTwo org
Update org defaults (registry, npm scope, CI bot, orb slug),
Makefile, orb metadata, all runtime script fallbacks, command/job
parameter defaults, CI config, examples, display strings, docs,
and test assertions. Internal API names (FABER_*, faber_helpers,
.faber.yml) are preserved. All 362 tests pass.
2026-02-21 13:46:37 -06:00
james.maesandClaude Opus 4.6 08e00fb4d4 Initial commit: Munitor orb (based on Faber)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-21 09:21:39 -06:00