Accept plural WIF_ADMIN_SUBJECTS in the revocation wrapper (multi-Workspace)#288
Merged
Merged
Conversation
…kspace) The Google directory-revocation feature is being extended to cover multiple separate Google Workspace tenants. The per-Workspace looping happens entirely inside infrahouse-toolkit's `ih-openvpn sync-google-users`; puppet's only part is the wrapper's required-var precheck. terraform-aws-openvpn will write a new plural WIF_ADMIN_SUBJECTS (comma-separated, one admin per tenant) into wif.env while keeping the singular WIF_ADMIN_SUBJECT for back-compat. The wrapper hard-required the singular, so it would wrongly fail if a future wif.env emitted only the plural. Change the precheck to require the always-present vars (GOOGLE_APPLICATION_CREDENTIALS, WIF_SA_EMAIL) unconditionally, then require at least ONE of WIF_ADMIN_SUBJECTS / WIF_ADMIN_SUBJECT. The wrapper does not parse the list -- it sources wif.env and runs the tool, which reads the env itself. No change to the cron, the compile-time fact gate, or the fact handling. Applied byte-identically to the development, sandbox, and global copies. Design notes: .claude/plans/TASK-multi-workspace-revocation.md. Desk-checked all four precheck cases: singular-only, plural-only, and both pass; neither -> misconfigured (exit 1, cron mails). Back-compat holds throughout the rollout since the module keeps emitting the singular too. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
infrahouse8
approved these changes
Jul 22, 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.
Puppet's (small) part of extending Google directory revocation to multiple Google Workspace tenants. The per-Workspace looping lives entirely in
infrahouse-toolkit'sih-openvpn sync-google-users; here the only change is the wrapper's required-var precheck. Design notes:.claude/plans/TASK-multi-workspace-revocation.md.The change
terraform-aws-openvpnwill write a new pluralWIF_ADMIN_SUBJECTS(comma-separated, one admin per tenant) intowif.env, keeping the singularWIF_ADMIN_SUBJECTfor back-compat:The wrapper hard-required the singular, so it would wrongly fail if a future
wif.envemitted only the plural. Now it requires the always-present vars unconditionally, then at least one admin-subject var:The wrapper doesn't parse the list — it sources
wif.envand runs the tool, which reads the env itself.Scope
wif.env. Confirmed: no.pptouched.ensure => latest+ release ordering.Testing
Desk-checked all four precheck cases against the rendered wrapper:
wif.envhasWIF_ADMIN_SUBJECT(old)WIF_ADMIN_SUBJECTS(new)misconfigured→ exit 1, cron mailsbash -nclean;puppet-lintclean (no manifest changed). Everything else — the EFSflock,index.txtnot-ready → quietexit 0, exit-78 →misconfigured, other non-zero → real failure — is unchanged.Rollout order (three repos)
infrahouse-toolkit≥ 2.62.0 ships first (ensure => latestpulls it).terraform-aws-openvpnemitsWIF_ADMIN_SUBJECTSintowif.env.🤖 Generated with Claude Code