AIROM is pre-release (
v0.1.0-dev, untagged). There are no prebuilt binaries yet, so CI
installs from source with go install. This resolves to a release tag once one exists.The workflow
.github/workflows/airom.yml
0 whether it finds
nothing or forty components. See exit codes.
What each piece does
permissions: security-events: write
permissions: security-events: write
Required by
github/codeql-action/upload-sarif to write results into the repository’s
Code Scanning alerts. contents: read is enough for actions/checkout. Grant nothing
else.-o sarif=airom.sarif
-o sarif=airom.sarif
-o is repeatable and takes format[=path]. Formats: cyclonedx, json, sarif,
table, yaml. Omitting =path sends that format to stdout — which is why -o table
above still prints a human-readable summary to the job log while the machine formats go
to files.AIROM’s SARIF defaults to level: "note", which is what GitHub Code Scanning renders.
--sarif-strict-kinds switches to spec-pure kind: "informational" — correct per the
SARIF spec, but GitHub displays those differently. Leave it off for this workflow.category: airom
category: airom
Keeps AIROM’s results in their own Code Scanning category so they do not collide with
CodeQL or another SARIF producer uploading to the same commit.
-o cyclonedx=airom.cdx.json
-o cyclonedx=airom.cdx.json
The CycloneDX AIBOM, archived as a build artifact so you can diff it release over
release.
--cdx-version selects 1.6 (default) or 1.7.The CycloneDX dependencies[] array is intentionally empty: AIROM does not fabricate
depends-on edges it cannot substantiate.Gating the build
Add--fail-on when you want a policy violation to fail the job. Keep it on its own
step so the SARIF upload runs first — a gated scan still writes all of its output before
the gate is evaluated.
Report first, then gate
Report on a PR, fail on main
--exit-code 0 evaluates the policy and still writes every output, but never fails the
build — so a pull request gets the SARIF results without a red check, while main gates.
Policy from the workflow context
Configuration via environment
Every flag has anAIROM_* equivalent, so you can hoist shared settings to the job. List
values are comma-separated.
Env instead of flags
AIROM_* > .airom.yaml > defaults. Unknown keys and unknown
AIROM_* variables fail loudly — a typo never silently does nothing. Committing an
.airom.yaml at the repo root keeps CI and local runs identical.
Scanning other targets
- Repository
- Container image
- Kubernetes manifests
Scanning the checkout with
fs is usually what you want in CI — the working tree is
already there. Use repo when you need git provenance, or to scan a different
repository.--offline asserts that the run touches no network. fs, a local repo path, and
image --input perform no network access regardless — the flag states the intent
explicitly in the job, which is worth doing in an air-gapped or egress-restricted runner.Reproducible, pinnable installs
@latest builds the newest commit today. Pin the module version once a tag exists, or
pin a commit now:
Pin the install
airom version prints the version, commit, and build date — the same ToolInfo recorded
in every AIBOM AIROM produces. Print it in CI so an artifact is always traceable to a
build.
Record what produced the AIBOM
Next
Exit codes
The full contract and the
--fail-on grammar.Output formats
SARIF, CycloneDX, JSON, YAML, table.