Skip to content

Manage the velnor-new release-tags ruleset and match live ruleset settings - #58

Merged
donbeave merged 1 commit into
mainfrom
i0-release-tags-682
Nov 14, 2026
Merged

donbeave merged 1 commit into
mainfrom
i0-release-tags-682

Conversation

@donbeave

@donbeave donbeave commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Summary

This PR brings the release-tags ruleset under Terraform management. It was created live on tailrocks/velnor-new today as step I0, the interim fix for tailrocks/velnor-new#682. It also brings this configuration back in line with the live rulesets, so the owner's next tofu apply imports the rulesets with no change and weakens no protection.

What ships

  • A per-repository tag_creation_rulesets option. Each entry is a tag ruleset with the creation rule for its include patterns and an always bypass for each user ID in bypass_user_ids.
  • velnor-new declares release-tags (refs/tags/rust-ci-v*, refs/tags/velnor-ci-v*, refs/tags/velnor-gen-v*, bypass user 139017) and the existing sdk-preview-owner-creation (refs/tags/sdk-preview-*, same bypass). Import blocks adopt live rulesets 27276267 and 26696396.
  • Per-repository strict_required_status_checks and protect_tags_update options. Both default to false, which keeps the current behavior for the other repositories.
  • A velnor_new_release_tags_reserved check that fails if the three patterns or the single-user bypass are removed.

What this addresses

  • #682. release-rust-ci-tools.yml publishes a release for any rust-ci-v* tag, and protect-tags blocks deleting and moving tags but not creating them. A tag on an unmerged commit could therefore publish. The new ruleset lets only the owner create these tags. In the design's R11, the velnor-release GitHub App replaces the owner bypass.

  • Drift that an apply would have weakened. A read-only plan of main against the live state (empty local state, import blocks only) showed these changes:

    • velnor-new protect-main: strict_required_status_checks_policy changes from true to false.
    • velnor-new and termpane protect-tags: the update rule is removed.
    • 17 repositories: protect-main replaces the live Required check with Policy and ci-required. The repositories are holla, holla-apt, homebrew-holla, homebrew-parallax, homebrew-ruxel, homebrew-tablerock, homebrew-velnor-legacy, parallax, parallax-telemetry-playground, pg-bigdecimal, ruxel, schemalane, tablerock, termrock, tracing-request-level, velnor-apt-legacy and velnor-legacy. The default-branch HEAD of each one reports a Required check run and neither of the other two checks, so an apply would have made every PR wait for checks that never arrive.

    This PR changes the configuration to match the live rulesets, using the new options and the new dco_required check template.

Not included

  • Rulesets that stay outside this module. parallax "stable tag protection" (refs/tags/v*; creation, update, deletion and non-fast-forward rules; bypass for repository role 5) and repo-scan protect-repo-scan-release-tags (refs/tags/repo-scan-v*; deletion and update rules) stay unmanaged. An apply does not touch them.
  • Pull-request parameter outside the provider. The live protect-main rulesets set require_extra_approval_for_unattributed_changes: true. Provider 6.13.0 has no argument for it, so this module cannot manage it.
  • Private repository without rulesets. tailrocks-asd-ste100-skills is private, and its rulesets API returns 403 ("Upgrade to GitHub Pro"). The module still declares rulesets for it. This PR does not change that.
  • No apply. Nothing in this PR has been applied.

Verify locally

Checkout

gh pr checkout 58

Static checks

Expected: tofu validate prints "Success! The configuration is valid."

tofu fmt -check -recursive
tofu init -backend=false -input=false -lockfile=readonly
tofu validate -no-color

Smoke

tofu plan -no-color

Expected: tag_creation["velnor-new/release-tags"] and tag_creation["velnor-new/sdk-preview-owner-creation"] show "will be imported" with no in-place change. No protect_main or protect_tags ruleset shows an update. I ran the targeted form of this plan against an empty local state with the velnor-new, termpane, holla, velnor-legacy and velnor-lab rulesets as targets. Every ruleset was imported with no change.

Migration notes

None. The import blocks adopt the two existing velnor-new tag rulesets on the next apply.

🤖 Generated with Claude Code

…tings

Adopt the release-tags ruleset created live for tailrocks/velnor-new#682
(owner-only creation of rust-ci-v*, velnor-ci-v*, and velnor-gen-v* tags)
and the existing sdk-preview-owner-creation ruleset through a new
per-repository tag_creation_rulesets option with import blocks.

Reconcile drift between the live rulesets and this configuration so the
next apply weakens nothing: velnor-new keeps strict required status
checks and the protect-tags update rule, termpane keeps the update rule,
and 17 repositories require DCO and Required, which their CI emits,
instead of the retired Policy and ci-required contexts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Alexey Zhokhov <alexey@zhokhov.com>
@donbeave
donbeave marked this pull request as ready for review November 14, 2026 19:45
@donbeave
donbeave merged commit cf2860f into main Nov 14, 2026
11 checks passed
@donbeave
donbeave deleted the i0-release-tags-682 branch November 14, 2026 19:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant