diff --git a/README.md b/README.md index 0ccd5a7..c097849 100644 --- a/README.md +++ b/README.md @@ -488,7 +488,7 @@ issue-type change before the first mutation. ## Metaserver development credentials The `development` environment of `atrinik/metaserver-worker` (repository ID -1324297032) holds the three value-free lifecycle entries consumed only by +1324297032) holds the two value-free lifecycle entries consumed only by `.github/workflows/deploy-development.yml`. Zoey Seraphina Rose, an Atrinik organization owner, is accountable for verification and rotation. @@ -496,11 +496,10 @@ organization owner, is accountable for verification and rotation. D1 Read permissions. Its account-wide edit authority can also edit PROD; the workflow's exact DEV configuration and resource fences provide the target boundary. `ATRINIK_DELIVERY_RESOURCE_READ_TOKEN` is account-owned with intended -Workers Scripts Read. `ATRINIK_PRODUCTION_BUILDS_READ_TOKEN` is user-scoped -with intended Workers CI Read and Workers Scripts Read for the retained-writer -fence. Do not describe any of these credentials as restricted to one Worker. +Workers Scripts Read. Do not describe either credential as restricted to one +Worker. -All three environment names were installed and verified on 2026-10-11; bounded +Both retained credential names were installed and verified on 2026-10-11; bounded runtime GET checks passed. Effective provider permission metadata is unreadable, and the deployment token's write permission has not yet been proven by its owning workflow. Name metadata does not verify values, scope or expiry. @@ -1188,9 +1187,16 @@ provenance for the promotion review. The names-only `production` environment inventory declares the reviewed production-promotion contract: protected branches enabled, -custom policies disabled, no custom patterns and no required reviewers. Solo -owner dispatch of the exact reviewed inputs remains the approval boundary. -The eight secret names and two variable names are desired state, not proof that +custom policies disabled, no custom patterns, and the organization owner +(`zoeyrose`, user ID `3865595`) as the single required reviewer, by owner +decision of 2026-11-14. Her dispatch of the exact reviewed inputs and her +approval of the resulting pending deployment together form the approval +boundary. `bin/validate` rejects any other reviewer set for this environment, +and every other recorded environment keeps an empty set; +`bin/verify-manual-settings` fails on live reviewer drift in either direction. +Neither records nor verifies `prevent_self_review` or administrator bypass for +this environment. +The seven secret names and one variable name are desired state, not proof that the environment or effective credentials exist. The recovery public-key input remains pending the owning workflow merge; provision it only after that reviewed consumer is merged. Provision through supported @@ -1246,9 +1252,9 @@ database identity. Required `Workers Scripts Edit` and `D1 Read` permissions remain the intended deployment contract; provider permission metadata and write capability are unproven. Provider creation and expiry remain unknown. Its 2027-01-10 rotation deadline is internal 90-day policy, not provider expiry. -The two owner-authorized shared read-only control-plane credentials retain their -2026-10-11 qualification and 2027-01-09 internal deadlines; expiry remains unknown. -Their separate production lifecycle entries declare desired placement, not +The owner-authorized shared `ATRINIK_DELIVERY_RESOURCE_READ_TOKEN` retains its +2026-10-11 qualification and 2027-01-09 internal deadline; expiry remains unknown. +Its separate production lifecycle entry declares desired placement, not installation or successful use by the production workflow. Provision and verify only after this inventory is reviewed and accepted. @@ -1487,14 +1493,19 @@ environment. The environment permits only the exact `main` branch and has no required reviewers, secrets, or variables. The desired Pages build type is `workflow`; the consuming workflow is `.github/workflows/daily-client-performance.yml`, bound by the immutable -`actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e` marker. +`actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346` marker. -The live legacy `main`-root source is a bounded pre-activation state only while +A legacy `main`-root source is a bounded pre-activation state only while that marker is absent from the default-branch workflow. `bin/verify-manual-settings` reports it as `PENDING`. Once the reviewed Classic workflow is merged, the same verifier requires the Actions source and fails on any lingering legacy source. It never changes the source itself. +Classic PR #547 merged the v5.0.1 deployment action update on 2026-10-03. +The inventory marker follows that reviewed immutable action. Read-only metadata +on 2026-10-31 showed the site already uses the Actions source; this verifies +configuration, not successful execution of the latest Pages deployment. + Before activation, verify the repository, current Pages site, environment, and the merged workflow without changing live state: @@ -1513,7 +1524,7 @@ gh api repos/atrinik/classic/environments/github-pages/variables \ --jq '{total_count,names:[.variables[].name]}' gh api 'repos/atrinik/classic/contents/.github/workflows/daily-client-performance.yml?ref=main' \ --jq -r .content | base64 --decode | \ - grep -F 'actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e' + grep -F 'actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346' ``` Require the stable repository identity and `main` default branch, exact site diff --git a/bin/validate b/bin/validate index a45ab4f..24ecc0e 100755 --- a/bin/validate +++ b/bin/validate @@ -828,9 +828,6 @@ jq -e \ elif .secret_name == "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN" then .credential_type == "cloudflare_account_token" and .required_scopes == ["Workers Scripts Read"] - elif .secret_name == "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN" then - .credential_type == "cloudflare_user_token" and - .required_scopes == ["Workers CI Read", "Workers Scripts Read"] else false end) end) ) and @@ -1186,7 +1183,16 @@ jq -e \ length <= 255 and test("^[a-z0-9][a-z0-9-]*[a-z0-9]$") ) and - (.required_reviewers == []) and + # Only metaserver production has a required reviewer: the organization + # owner, by owner decision of 2026-11-14. Every other environment has none. + ( + if .repository == "atrinik/metaserver-worker" and + .environment == "production" + then + .repository_id == 1324297032 and + .required_reviewers == [{type: "User", id: 3865595}] + else .required_reviewers == [] end + ) and ( .deployment_branch_policy | (keys == [ diff --git a/bin/verify-manual-settings b/bin/verify-manual-settings index 796988f..2576cb8 100755 --- a/bin/verify-manual-settings +++ b/bin/verify-manual-settings @@ -586,8 +586,10 @@ while IFS= read -r environment_record; do exit 1 fi + # Project both sides to the same key order; the strings are compared below. expected_reviewers=$(jq -c \ - '.required_reviewers | sort_by(.type, .id)' <<<"${environment_record}") + '[.required_reviewers[] | {type, id}] | sort_by(.type, .id)' \ + <<<"${environment_record}") reviewer_rule_count=$(jq \ '[.protection_rules[] | select(.type == "required_reviewers")] | length' \ "${environment_file}") diff --git a/config/manual-settings.json b/config/manual-settings.json index e1f02ff..5005b34 100644 --- a/config/manual-settings.json +++ b/config/manual-settings.json @@ -313,13 +313,10 @@ "ATRINIK_DEVELOPMENT_CORE_CONFIG", "ATRINIK_DEVELOPMENT_PUBLISHER_CONFIG", "ATRINIK_DEVELOPMENT_RENDEZVOUS_CONFIG", - "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN", "CLOUDFLARE_ACCOUNT_ID", "CLOUDFLARE_API_TOKEN" ], - "variable_names": [ - "ATRINIK_PRODUCTION_WRITER_FENCE_POLICY" - ] + "variable_names": [] }, { "deployment_branch_policy": { @@ -330,11 +327,15 @@ "environment": "production", "repository": "atrinik/metaserver-worker", "repository_id": 1324297032, - "required_reviewers": [], + "required_reviewers": [ + { + "id": 3865595, + "type": "User" + } + ], "secret_names": [ "ATRINIK_DELIVERY_RESOURCE_POLICY", "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN", - "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN", "ATRINIK_PRODUCTION_CORE_CONFIG", "ATRINIK_PRODUCTION_PUBLISHER_CONFIG", "ATRINIK_PRODUCTION_RENDEZVOUS_CONFIG", @@ -342,14 +343,13 @@ "CLOUDFLARE_API_TOKEN" ], "variable_names": [ - "ATRINIK_PRODUCTION_RECOVERY_PUBLIC_KEY", - "ATRINIK_PRODUCTION_WRITER_FENCE_POLICY" + "ATRINIK_PRODUCTION_RECOVERY_PUBLIC_KEY" ] } ], "github_pages_sites": [ { - "activation_marker": "actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e", + "activation_marker": "actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346", "build_type": "workflow", "environment": "github-pages", "https_enforced": true, @@ -459,28 +459,6 @@ "secret_name": "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN", "secret_scope": "environment" }, - { - "credential_type": "cloudflare_user_token", - "consumers": [ - ".github/workflows/deploy-development.yml" - ], - "environment": "development", - "last_verified_on": "2026-10-11", - "owner": "Zoey Seraphina Rose (Atrinik organization owner)", - "purpose": "Read retained Builds and Worker settings to prove the stopped-writer fence without deployment.", - "repository": "atrinik/metaserver-worker", - "repository_id": 1324297032, - "required_scopes": [ - "Workers CI Read", - "Workers Scripts Read" - ], - "rotate_by": "2027-01-09", - "rotation_cadence_days": 90, - "rotation_owner": "Zoey Seraphina Rose (Atrinik organization owner)", - "runbook": "README.md#metaserver-development-credentials", - "secret_name": "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN", - "secret_scope": "environment" - }, { "consumers": [ ".github/workflows/promote-production.yml" @@ -523,28 +501,6 @@ "runbook": "README.md#metaserver-production-credentials", "secret_name": "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN", "secret_scope": "environment" - }, - { - "consumers": [ - ".github/workflows/promote-production.yml" - ], - "credential_type": "cloudflare_user_token", - "environment": "production", - "last_verified_on": "2026-10-11", - "owner": "Zoey Seraphina Rose (Atrinik organization owner)", - "purpose": "Read retained Builds and Worker settings to prove the stopped-writer fence without deployment. Reuse in the production control-plane workflow is owner-authorized; this record declares production placement, which remains pending. Provider expiry is unknown and rotate_by is internal policy.", - "repository": "atrinik/metaserver-worker", - "repository_id": 1324297032, - "required_scopes": [ - "Workers CI Read", - "Workers Scripts Read" - ], - "rotate_by": "2027-01-09", - "rotation_cadence_days": 90, - "rotation_owner": "Zoey Seraphina Rose (Atrinik organization owner)", - "runbook": "README.md#metaserver-production-credentials", - "secret_name": "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN", - "secret_scope": "environment" } ], "github_packages_actions_access": [ diff --git a/tests/validate-manual-credentials.sh b/tests/validate-manual-credentials.sh index 8d4d545..db660c2 100755 --- a/tests/validate-manual-credentials.sh +++ b/tests/validate-manual-credentials.sh @@ -198,7 +198,7 @@ jq -e ' jq -e ' [.github_actions_credentials[] | select(.environment == "development")] as $credentials | - ($credentials | length) == 3 and + ($credentials | length) == 2 and all($credentials[]; .repository == "atrinik/metaserver-worker" and .repository_id == 1324297032 and .environment == "development" and .consumers == [".github/workflows/deploy-development.yml"] and @@ -206,13 +206,13 @@ jq -e ' .rotation_cadence_days == 90 and .owner == "Zoey Seraphina Rose (Atrinik organization owner)" ) and ([$credentials[].secret_name] | sort) == [ - "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN", "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN", "CLOUDFLARE_API_TOKEN" + "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN", "CLOUDFLARE_API_TOKEN" ] ' "${root}/config/manual-settings.json" >/dev/null jq -e ' [.github_actions_credentials[] | select(.environment == "production")] as $credentials | - ($credentials | length) == 3 and + ($credentials | length) == 2 and all($credentials[]; .repository == "atrinik/metaserver-worker" and .repository_id == 1324297032 and .consumers == [".github/workflows/promote-production.yml"] and @@ -223,7 +223,7 @@ jq -e ' else .last_verified_on == "2026-10-11" and .rotate_by == "2027-01-09" end) ) and ([$credentials[].secret_name] | sort) == [ - "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN", "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN", "CLOUDFLARE_API_TOKEN" + "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN", "CLOUDFLARE_API_TOKEN" ] ' "${root}/config/manual-settings.json" >/dev/null @@ -244,7 +244,8 @@ for invalid in \ '.github_actions_credentials[-1].consumers = [".github/workflows/deploy-development.yml"]' \ '.github_actions_credentials[-1].runbook = "README.md#metaserver-development-credentials"' \ '.github_actions_credentials[-1].required_scopes += ["Workers Scripts Edit"]' \ - '.github_actions_credentials[-1].credential_type = "cloudflare_account_token"'; do + '.github_actions_credentials[-1].credential_type = "cloudflare_user_token"' \ + '.github_actions_credentials[-1] |= (.secret_name = "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN" | .credential_type = "cloudflare_user_token" | .required_scopes = ["Workers CI Read", "Workers Scripts Read"])'; do jq "$invalid" "${temporary}/production-credentials.json" >"${temporary}/config/manual-settings.json" if ATRINIK_VALIDATION_TODAY=2026-10-18 "${temporary}/bin/validate" >/dev/null 2>&1; then echo "error: validator accepted malformed PROD credential lifecycle: ${invalid}" >&2 @@ -255,7 +256,7 @@ done for invalid in \ '.github_actions_credentials[1].required_scopes = ["Workers Scripts Read"]' \ '.github_actions_credentials[2].credential_type = "cloudflare_user_token"' \ - '.github_actions_credentials[3].environment = "production"' \ + '(.github_actions_credentials[] | select(.environment == "development" and .secret_name == "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN")).environment = "production"' \ '.github_actions_credentials[1].repository_id = 1' \ '.github_actions_credentials[1].consumers = [".github/workflows/publish.yml"]' \ '.github_actions_credentials[1].credential_value = "secret"'; do diff --git a/tests/validate-manual-environments.sh b/tests/validate-manual-environments.sh index a41a0e4..8d832a6 100755 --- a/tests/validate-manual-environments.sh +++ b/tests/validate-manual-environments.sh @@ -103,28 +103,27 @@ jq -e ' "ATRINIK_DEVELOPMENT_CORE_CONFIG", "ATRINIK_DEVELOPMENT_PUBLISHER_CONFIG", "ATRINIK_DEVELOPMENT_RENDEZVOUS_CONFIG", - "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN", "CLOUDFLARE_ACCOUNT_ID", "CLOUDFLARE_API_TOKEN" ], - variable_names: ["ATRINIK_PRODUCTION_WRITER_FENCE_POLICY"] + variable_names: [] }) and any(.github_actions_environments[]; . == { deployment_branch_policy: {custom_branch_policies: false, patterns: [], protected_branches: true}, environment: "production", repository: "atrinik/metaserver-worker", repository_id: 1324297032, - required_reviewers: [], + required_reviewers: [{id: 3865595, type: "User"}], secret_names: [ "ATRINIK_DELIVERY_RESOURCE_POLICY", "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN", - "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN", "ATRINIK_PRODUCTION_CORE_CONFIG", + "ATRINIK_PRODUCTION_CORE_CONFIG", "ATRINIK_PRODUCTION_PUBLISHER_CONFIG", "ATRINIK_PRODUCTION_RENDEZVOUS_CONFIG", "CLOUDFLARE_ACCOUNT_ID", "CLOUDFLARE_API_TOKEN" ], - variable_names: ["ATRINIK_PRODUCTION_RECOVERY_PUBLIC_KEY", "ATRINIK_PRODUCTION_WRITER_FENCE_POLICY"] + variable_names: ["ATRINIK_PRODUCTION_RECOVERY_PUBLIC_KEY"] }) and .github_pages_sites == [{ - activation_marker: "actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e", + activation_marker: "actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346", build_type: "workflow", environment: "github-pages", https_enforced: true, @@ -164,6 +163,94 @@ rewrite_manual_settings \ assert_invalid 'a required reviewer outside the declared empty set' reset_manual_settings +rewrite_manual_settings \ + '.github_actions_environments[0].required_reviewers = [{type: "User", id: 3865595}]' +assert_invalid 'the organization owner as reviewer outside metaserver production' +reset_manual_settings + +assert_invalid_production_reviewers() { + local reviewers=$1 + local description=$2 + + cp "${root}/config/manual-settings.json" \ + "${temporary}/config/manual-settings.json" + rewrite_manual_settings " + (.github_actions_environments[] | + select(.repository == \"atrinik/metaserver-worker\" and + .environment == \"production\") | + .required_reviewers) = ${reviewers} + " + assert_invalid "${description}" +} + +assert_invalid_production_reviewers '[]' \ + 'metaserver production without its required owner reviewer' +assert_invalid_production_reviewers '[{type: "User", id: 1}]' \ + 'metaserver production with a different required reviewer' +assert_invalid_production_reviewers '[{type: "Team", id: 3865595}]' \ + 'metaserver production with a Team required reviewer' +assert_invalid_production_reviewers \ + '[{type: "User", id: 3865595}, {type: "User", id: 1}]' \ + 'metaserver production with an extra required reviewer' +assert_invalid_production_reviewers \ + '[{type: "User", id: 3865595}, {type: "User", id: 3865595}]' \ + 'metaserver production with a duplicate required reviewer' +assert_invalid_production_reviewers '[{type: "User", id: "3865595"}]' \ + 'metaserver production with a string reviewer ID' +assert_invalid_production_reviewers '[{type: "User"}]' \ + 'metaserver production with a reviewer without an ID' +assert_invalid_production_reviewers \ + '[{type: "User", id: 3865595, login: "zoeyrose"}]' \ + 'metaserver production with an unrecorded reviewer field' +assert_invalid_production_reviewers '[3865595]' \ + 'metaserver production with a bare reviewer ID' +assert_invalid_production_reviewers 'null' \ + 'metaserver production without a reviewer set' +assert_invalid_production_reviewers '{type: "User", id: 3865595}' \ + 'metaserver production with a reviewer object instead of a set' + +cp "${root}/config/manual-settings.json" \ + "${temporary}/config/manual-settings.json" +rewrite_manual_settings ' + (.github_actions_environments[] | + select(.repository == "atrinik/metaserver-worker" and + .environment == "development") | + .required_reviewers) = [{type: "User", id: 3865595}] +' +assert_invalid 'the production owner reviewer on metaserver development' + +reset_manual_settings +rewrite_manual_settings ' + .github_actions_environments[0] += { + environment: "production", + repository: "atrinik/metaserver-worker", + repository_id: 1324297032, + required_reviewers: [{type: "User", id: 3865595}] + } +' +"${temporary}/bin/validate" >/dev/null +rewrite_manual_settings \ + '.github_actions_environments[0].environment = "staging"' +assert_invalid 'the production owner reviewer on another metaserver environment' +rewrite_manual_settings ' + .github_actions_environments[0].environment = "production" | + .github_actions_environments[0].repository = "atrinik/classic" | + .github_actions_environments[0].repository_id = 1327289971 +' +assert_invalid 'the production owner reviewer on another repository' +rewrite_manual_settings \ + '.github_actions_environments[0].repository_id = 1324297032' +assert_invalid 'the production owner reviewer under another repository name' +rewrite_manual_settings ' + .github_actions_environments[0].repository = "atrinik/metaserver-worker" | + .github_actions_environments[0].repository_id = 1 +' +assert_invalid 'the production owner reviewer under another repository ID' +rewrite_manual_settings \ + '.github_actions_environments[0].required_reviewers = []' +assert_invalid 'metaserver production without a reviewer under another repository ID' +reset_manual_settings + rewrite_manual_settings ' .github_actions_environments[0].deployment_branch_policy = { custom_branch_policies: false, diff --git a/tests/verify-manual-settings.sh b/tests/verify-manual-settings.sh index 1411aa6..9f82def 100755 --- a/tests/verify-manual-settings.sh +++ b/tests/verify-manual-settings.sh @@ -312,7 +312,7 @@ repos/atrinik/classic/pages) workflow='name: Daily Classic client performance' if [[ ${FAKE_GH_SCENARIO} == pages-active || ${FAKE_GH_SCENARIO} == pages-activation-missing ]]; then - workflow='uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e' + workflow='uses: actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346' fi if [[ ${FAKE_GH_SCENARIO} == pages-workflow-metadata-drift ]]; then jq -n '{type: "dir", encoding: "none", content: null}' @@ -610,26 +610,48 @@ repos/atrinik/classic/pages) }' ;; repos/atrinik/metaserver-worker/environments/production) - jq -n '{name: "production", deployment_branch_policy: { + reviewers='[{type: "User", reviewer: {id: 3865595, login: "zoeyrose"}}]' + case ${FAKE_GH_SCENARIO} in + production-reviewer-different) + reviewers='[{type: "User", reviewer: {id: 1, login: "reviewer"}}]' + ;; + production-reviewer-team) + reviewers='[{type: "Team", reviewer: {id: 3865595, slug: "maintainers"}}]' + ;; + production-reviewer-extra) + reviewers='[{type: "User", reviewer: {id: 3865595, login: "zoeyrose"}}, + {type: "User", reviewer: {id: 1, login: "reviewer"}}]' + ;; + esac + if [[ ${FAKE_GH_SCENARIO} == production-reviewer-missing ]]; then + rules='[{type: "branch_policy"}]' + elif [[ ${FAKE_GH_SCENARIO} == production-reviewer-duplicate-rule ]]; then + rules="[{type: \"branch_policy\"}, + {type: \"required_reviewers\", reviewers: ${reviewers}}, + {type: \"required_reviewers\", reviewers: ${reviewers}}]" + else + rules="[{type: \"branch_policy\"}, {type: \"required_reviewers\", + prevent_self_review: false, reviewers: ${reviewers}}]" + fi + jq -n "{name: \"production\", deployment_branch_policy: { protected_branches: true, custom_branch_policies: false - }, protection_rules: [{type: "branch_policy"}]}' + }, protection_rules: ${rules}}" ;; "repos/atrinik/metaserver-worker/environments/production/deployment-branch-policies?per_page=100&page=1") echo "error: protected production environment must not request custom policies" >&2 exit 79 ;; "repos/atrinik/metaserver-worker/environments/production/secrets?per_page=100&page=1") - jq -n '{total_count: 8, secrets: [ + jq -n '{total_count: 7, secrets: [ {name: "ATRINIK_DELIVERY_RESOURCE_POLICY"}, {name: "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN"}, - {name: "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN"}, {name: "ATRINIK_PRODUCTION_CORE_CONFIG"}, + {name: "ATRINIK_PRODUCTION_CORE_CONFIG"}, {name: "ATRINIK_PRODUCTION_PUBLISHER_CONFIG"}, {name: "ATRINIK_PRODUCTION_RENDEZVOUS_CONFIG"}, {name: "CLOUDFLARE_ACCOUNT_ID"}, {name: "CLOUDFLARE_API_TOKEN"} ]}' ;; "repos/atrinik/metaserver-worker/environments/production/variables?per_page=100&page=1") - jq -n '{total_count: 2, variables: [ - {name: "ATRINIK_PRODUCTION_RECOVERY_PUBLIC_KEY"}, - {name: "ATRINIK_PRODUCTION_WRITER_FENCE_POLICY"} + jq -n '{total_count: 1, variables: [ + {name: "ATRINIK_PRODUCTION_RECOVERY_PUBLIC_KEY"} ]}' ;; repos/atrinik/metaserver-worker/environments/development) @@ -652,19 +674,18 @@ repos/atrinik/metaserver-worker/environments/development) jq -n '{total_count: 0, secrets: []}' exit 0 fi - jq -n '{total_count: 8, secrets: [ + jq -n '{total_count: 7, secrets: [ {name: "ATRINIK_DELIVERY_RESOURCE_POLICY"}, {name: "ATRINIK_DELIVERY_RESOURCE_READ_TOKEN"}, {name: "ATRINIK_DEVELOPMENT_CORE_CONFIG"}, {name: "ATRINIK_DEVELOPMENT_PUBLISHER_CONFIG"}, {name: "ATRINIK_DEVELOPMENT_RENDEZVOUS_CONFIG"}, - {name: "ATRINIK_PRODUCTION_BUILDS_READ_TOKEN"}, {name: "CLOUDFLARE_ACCOUNT_ID"}, {name: "CLOUDFLARE_API_TOKEN"} ] | map(. + {updated_at: "2026-10-11T00:00:00Z"})}' ;; "repos/atrinik/metaserver-worker/environments/development/variables?per_page=100&page=1") - jq -n '{total_count: 1, variables: [{name: "ATRINIK_PRODUCTION_WRITER_FENCE_POLICY"}]}' + jq -n '{total_count: 0, variables: []}' ;; repos/atrinik/classic/environments/discord-release) if [[ ${FAKE_GH_SCENARIO} == missing-environment ]]; then @@ -1171,6 +1192,11 @@ environment_failures=( branch-mode-drift branch-policy-drift extra-reviewer + production-reviewer-missing + production-reviewer-different + production-reviewer-team + production-reviewer-extra + production-reviewer-duplicate-rule wait-timer custom-protection-rule missing-environment-secret @@ -1204,6 +1230,12 @@ grep -Fq 'deployment branch mode drift' \ grep -Fq 'deployment branch policy drift' \ "${temporary}/branch-policy-drift.err" grep -Fq 'required reviewer drift' "${temporary}/extra-reviewer.err" +for scenario in production-reviewer-missing production-reviewer-different \ + production-reviewer-team production-reviewer-extra \ + production-reviewer-duplicate-rule; do + grep -Fq 'required reviewer drift for atrinik/metaserver-worker production' \ + "${temporary}/${scenario}.err" +done grep -Fq 'protection rule drift' "${temporary}/wait-timer.err" grep -Fq 'protection rule drift' "${temporary}/custom-protection-rule.err" grep -Fq 'environment secret-name drift' \