Repository navigation
feat: scaffold, plugin config and rule parameters - #1
Open
ccf-lisa[bot] wants to merge 4 commits into
Open
ccf-lisa[bot] wants to merge 4 commits into
ccf-lisa[bot] wants to merge 4 commits into
Conversation
Port of the PoC's effector-github-settings scaffold: CI and release from plugin-template (adapted for an effector: binary "plugin", no protocol annotation), the operator-only plugin config (token, api_url), and the remediate-apply capability's params schema with its parsing. go.mod replaces the agent and api with sibling checkouts until the final PR of the stack. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important Review skippedBot user detected. To trigger a single review, invoke the
|
Replace the plugin-template workflows (push -> test, any tag -> goreleaser + gooci) with callers of compliance-framework/workflows v1.9.2, as plugin-github-repositories does: ci (ci-go-plugin, release-checks, notify-failure), release-please, release (release-go-plugin on release: published), preview (:pr-<n> for PRs labelled preview) and cut-prerelease (vX.Y.Z-rcN). The shared release workflow moves :latest only for a final tag, so the rc guard in the old upload step goes away. release-please-config.json copies the shared defaults; the manifest is seeded at 0.0.0 (no release yet), so the first release PR proposes initial-version 0.1.0. goreleaser gets release.prerelease: auto and replace_existing_artifacts, which the shared release job checks.
The plugin reads token once at Configure, and an installation token expires after an hour: it needs external rotation and an agent restart.
This was referenced Dec 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stack 1/5 for the new
effector-github-settingsplugin: scaffold and rule parameters.Implements part 1 of Plugins → effector-github-settings in the effectors implementation plan, per the LLD (Manifest, Rule parameters) and action parameters. Ported from the PoC (
effectors-poc/effector-github-settings, brancheffectors-phase1).What
compliance-framework/workflows(see CI and release).Makefile(build,test,lint,tidy-check),.goreleaser.yaml,.gitignore,release-please-config.json,.release-please-manifest.json.internal/config.go: operator-only plugin config (tokenrequired,api_urloptional); the plugin takes no action config (every key is an error pointing atparams.defaults). Errors never quote the token.internal/params.go: theremediate-applycapability'sparams_schema(lowercase snake_case names,x-ccf-order,x-ccf-depends-on) and parsing.modedefaults todry-runand every remediation is off by default.params.ValidateSchema, its defaults equal the Go defaults, values validate;keepparsing (spaces, case-insensitive,@, invalid logins); config errors.CI and release
Modeled on
plugin-github-repositories(master): thin callers of the sharedcompliance-framework/workflowsreusable workflows, all pinned to v1.9.2 (dc74348), withpush: branches: [main].ci.ymlci-go-plugin.yml,release-checks.yml,notify-failure.ymlgo mod tidy, toolchain line,go test, golangci-lint with the shared base config (no repo.golangci.yml), goreleaser check + snapshot build, actionlint, PR title, osv-scan;requiredis the one check to require. release-checks runs only on release-please PRs.release-please.ymlrelease-please.ymlmain: opens/updates the release PR; merging it tagsvX.Y.Zand publishes the release (as ccf-release-bot).release.ymlrelease-go-plugin.ymlrelease: published: goreleaser attaches the archives, gooci uploadsdist/once toghcr.io/compliance-framework/effector-github-settings:vX.Y.Z, and crane points:latestat the same digest only for a final tag (an rc never moves:latest; the shared workflow decides that from the tag name).preview.ymlpreview.yml(kind: go-plugin,on-main: false):pr-<number>for PRs labelledpreview; no:mainpreviews.cut-prerelease.ymlcut-prerelease.ymlworkflow_dispatch: tagsvX.Y.Z-rcNfrom the open release PR's version and creates a prerelease.release-please-config.jsoncopies the sharedrelease-please/defaults.json(bump-minor-pre-major,initial-version: "0.1.0", changelog sections) pluspackages: {".": {"release-type": "go"}};.release-please-manifest.jsonis seeded at0.0.0(no release yet, as the workflows repo bootstrapped), so the first release PR proposes0.1.0..goreleaser.yamlgainsrelease: {prerelease: auto, replace_existing_artifacts: true}, which the shared release job checks. Builds (binaryplugin, linux/darwin,-X internal.Version) are unchanged.release.ymlpasses noprotocol-version. The shared workflow has no way to skip the annotation, so artifacts carry its defaultorg.ccf.plugin.protocol.version=2; the agent ignores it fortype: effector.push.yml,test.yml,build-and-upload.ymland the tag-pushrelease.yml(this replaces the earlierfix: pin CI actions, keep rc tags off :latestworkflow changes).bodycloseanderrorlint; the GitHub client in 2/5 is adjusted for them.releaseenvironment with the ccf-release-bot secrets (RELEASE_BOT_APP_ID,RELEASE_BOT_PRIVATE_KEY, applied by the workflowsrepo-settingsrun), theSLACK_BOT_TOKENsecret for CI failure notifications (optional), and GHCR write access for the package (packages: writefromGITHUB_TOKEN; link the package to this repo if it already exists). Require theci / requiredcheck onmain.Dependencies (temporary)
go.modhasreplace github.com/compliance-framework/agent => ../agentandreplace github.com/compliance-framework/api => ../api, commented as temporary: build with sibling checkouts of agent ateffectors/09-cmd-effector-mode(agent#176) and api ateffectors/26-effectors-e2e(api#626). CI'sgo,golangci-lintandgoreleaserjobs (and sorequired) fail on module resolution (replacement directory ../agent does not exist) until the final PR of this stack (chore(deps): use agent v0.10.0-rc1 and api v0.23.0-rc1); accepted per the plan's "Build everything before releasing".Deviations from the PoC
api_urlmust be https; http only for localhost/loopback (tests), and no userinfo: the token goes with every call.mainpackage yet: it arrives with the plugin in 4/5.Local gate (with the sibling checkouts)
go build ./...,go vet ./...,go test -race ./..., golangci-lint v2.15.0 with the shared workflows config (0 issues), gofmt,go mod tidyclean, actionlint v1.7.12 clean,goreleaser checkvalid. On GitHub the shared jobs that need no module resolution pass (actionlint, pr-title, osv-scan, notify, preview).Counted lines: 879 (go.sum excluded).
🤖 Generated with Claude Code