delegation — version 2.3

Source: presets/delegation.satz

Purpose

Delegated access, the base: one identity per delegation. A delegation gives a team — or a product, a service — access to a part of the organization's resources from an estate of its own, beside this one. This pack is the half every delegation has, whatever is delegated: an infrastructure project with the service account the team's pipelines run as and the bucket its states live in, the estate account user group whose members may act as that account, and that group's right to act as it. WHAT is delegated — the resources a workload needs and the estate account's roles on them — is another pack's: folders (presets/delegated-folders.satz), Google projects (presets/delegated-projects.satz), each entry of which names the delegation whose account works in it.

ONE LIST. One entry of delegations is one identity: { name = "shop" estate_account_user_group = "gcp-shop-admins@example.com" } bound in the estate, added with satz add-entry, or requested by the team as contributes_delegations in a small pack of its own, checked with satz check-request and vendored by pull request. A name is lowercase letters, digits and -, starting with a letter.

PER DELEGATION. The infrastructure project {customer_shortname}-deploy-<name> in the infrastructure folder, google_folder.infra_folder, beside the organization's own, billed to the infrastructure billing account, with the APIs of the entry's apis: the team's calls are billed to this project, so an API its resources' calls need is asked for here. Inside it the account svc-deploy-<name> and the state bucket {customer_shortname}-deploy-<name>-state, which the account may write; the estate account user group reads the project and may act as the account — that account only. On the billing account the account holds the entry's billing_roles (roles/billing.user unless the entry says more), on the organization delegation_organization_roles — roles/browser and nothing else by default: an interface looks a folder up by its name among its parent's folders, and that listing needs resourcemanager.folders.list on the parent.

THE ESTATE ACCOUNT USER GROUP. The group of the entry's estate_account_user_group address is created, empty, in the customer's directory, labeled deploy_<name>_users. Who is a member is decided in the directory: someone with directory rights adds the workload team's people to it. Creating a group needs the Groups Admin role in the Google admin console for the organization's estate account (satz update-prerequisites names it); an estate on the customer's own groups assigns it once. A group that exists already is taken over once, before the first apply that creates it: satz adopt --only google_cloud_identity_group --execute --import which imports the group into the organization's state; its members stay as they are.

AN ENTRY THAT ASKS FOR MORE. apis and billing_roles are lists, and an entry that states one states it whole: the six APIs below plus its own, roles/billing.user plus its own.

WHAT THE WORKLOAD ESTATE READS. The interface delegation-<name>, taken to its interfaces/incoming/ folder: infrastructure_project_id (its infrastructure project), estate_account and its account id estate_account_id, state_bucket, estate_account_user_group, and what was delegated to the account beside its targets — delegated_billing_roles, delegated_apis — which tell the workload's team what the account holds; satz checks no role in a workload estate. satz init --from writes the workload estate from it, reading its estate account (svc_iac_account, infra_project_name) and its state bucket by the folder's name. Each target's own interface is taken beside it.

NO CLAIM. A delegation is an identity, not a control: this pack witnesses nothing.

Use it

params {
  use_delegation = true

  // the pack's own defaults — copy only the lines you change
  delegations = []
  delegation_organization_roles = [ "roles/browser" ]
  delegation_group_roles = [
    "roles/iam.serviceAccountTokenCreator",
    "roles/iam.serviceAccountUser",
  ]
}

use "presets/delegation.satz" when use_delegation

use_delegation is the gate: while it is falsy the pack contributes nothing — no resources, no params, no claims. It is declared by estate_map, and the estate's own binding wins.

Needs from outside the pack:

Params

param default
delegations []
delegation_organization_roles [ "roles/browser" ]
delegation_group_roles [ "roles/iam.serviceAccountTokenCreator", "roles/iam.serviceAccountUser" ]

Contributes

resource type labels
google_billing_account_iam_member billing_account_id (grant map), one per entry of delegations, by name
google_cloud_identity_group one per entry of delegations, by name
google_organization_iam_member one per entry of delegations, by name
google_project one per entry of delegations, by name

Exports

Outputs of the HCL code and values of the interfaces under interfaces/outgoing/ in every estate that uses this pack: a core export is carried by every interface, another one by its own interface and every interface that uses it. An interface a pack declares is common: every project's folder carries it.

interface output value description
delegation-{each.name} infrastructure_project_id "{customer_shortname}-deploy-{each.name}" The delegation's infrastructure project: the team's plans are billed to it
delegation-{each.name} estate_account "svc-deploy-{each.name}@{customer_shortname}-deploy-{each.name}.iam.gserviceaccount.com" The service account the workload estates run as
delegation-{each.name} estate_account_id "svc-deploy-{each.name}" The estate account's id, the part of its address before the @: a workload estate's svc_iac_account
delegation-{each.name} state_bucket "{customer_shortname}-deploy-{each.name}-state" The bucket the workload estates keep their states in
delegation-{each.name} estate_account_user_group "{each.estate_account_user_group}" The group whose members may act as the account
delegation-{each.name} account_group_roles delegation_group_roles What that group holds on the account
delegation-{each.name} billing_account billing_account_infra The billing account a new project is linked to, and a budget is created on
delegation-{each.name} delegated_billing_roles each.billing_roles The roles the account holds on the billing account
delegation-{each.name} delegated_apis each.apis The APIs enabled on the delegation's infrastructure project

delegation-{each.name} is written once per entry of delegations, named by the entry's name, and each is one project's own interface, not a common one.

List params

What a project may add to this pack's lists, through contributes_<param> in a file the estate uses after a reviewed pull request; satz check-request checks such a file.

list key fields description
delegations name name matching [a-z][a-z0-9-]*, estate_account_user_group matching [^@: ]+@[^@: ]+, apis, billing_roles A delegation: its name, the address of the group that may act as its account, which the delegation creates, the APIs of its infrastructure project and its roles on the billing account

Claims

None — this pack proves no control by itself.

History

version date change
2.3 2026-11-28 the delegation's estate account holds roles/serviceusage.serviceUsageConsumer on its own infrastructure project: a workload estate bills every call there, and without it Google refuses the first call into the workload's projects (serviceusage.services.use denied)
2.2 2026-11-27 each delegation's estate account user group is created, empty: a google_cloud_identity_group at the entry's estate_account_user_group address in the customer's directory, deploy_<name>_users, and the group's grants wait for it; its members are added in the directory. A plan shows one group created per delegation. An estate whose group exists already imports it once, before the first apply: satz adopt <estate> --only google_cloud_identity_group --execute --import. The organization's estate account needs Groups Admin in the Google admin console
2.1 2026-11-20 the interface delegation-<name> also exports estate_account_id, the estate account's id svc-deploy-<name>, which a workload estate reads as its svc_iac_account; nothing emitted changes
2.0 2026-11-19 the entry field owner_group of delegations is estate_account_user_group; the exports iac_account, account_group and deploy_project_id are estate_account, estate_account_user_group and infrastructure_project_id; delegation_project_folder and its question are gone — every delegation's infrastructure project is created in google_folder.infra_folder; the statement is entries (ADR 0096; BREAKING, see Breaking changes)
1.0 2026-11-19 first version, the base of delegated access, from the account half of folder_workload and project_workload: one entry of delegations ({ name owner_group apis billing_roles }) is an infrastructure project, the account svc-deploy-<name>, its state bucket and the group that may act as it; the interface is delegation-<name>; what is delegated is delegated_folders and delegated_projects, each entry naming its delegation (ADR 0093; BREAKING, see Breaking changes)

The whole library's history: the changelog in presets/CHANGELOG.md.

Notes

No notes yet.