Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion fast/stages/0-org-setup/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -545,7 +545,7 @@ iam_by_principals:
- roles/essentialcontacts.admin
# [...]
iam_by_principals_additive:
$iam_principals:gcp-billing-admins:
$iam_principals:gcp-organization-admins:
- roles/billing.admin
```

Expand Down
11 changes: 2 additions & 9 deletions fast/stages/0-org-setup/organization.tf
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,9 @@ locals {
? try(local.defaults.organization.id, local.organization.id)
: local.organization.id
)
# build map of predefined groups if organization domain is set
# define domain principal if organization domain is set
org_iam_principals = local.organization.domain == null ? {} : {
domain = "domain:${local.organization.domain}"
gcp-billing-admins = "group:gcp-billing-admins@${local.organization.domain}"
gcp-devops = "group:gcp-devops@${local.organization.domain}"
gcp-network-admins = "group:gcp-network-admins@${local.organization.domain}"
gcp-organization-admins = "group:gcp-organization-admins@${local.organization.domain}"
gcp-secops-admins = "group:gcp-secops-admins@${local.organization.domain}"
gcp-security-admins = "group:gcp-security-admins@${local.organization.domain}"
gcp-support = "group:gcp-support@${local.organization.domain}"
domain = "domain:${local.organization.domain}"
}
org_access_levels = {
for k, v in module.organization[0].access_levels : k => v.id
Expand Down
1 change: 1 addition & 0 deletions fast/stages/0-org-setup/output-files.tf
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ locals {
local.ctx.project_ids,
module.factory.project_ids
)
pubsub_topics = module.factory.pubsub_topics
storage_buckets = module.factory.storage_buckets
tag_keys = merge(
local.ctx.tag_keys,
Expand Down
10 changes: 2 additions & 8 deletions tests/fast/stages/s0_org_setup/caa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ values:
google_storage_bucket_object.tfvars["globals"]:
bucket: ft0-prod-iac-core-0-iac-outputs
cache_control: null
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_disposition: null
content_encoding: null
content_language: null
Expand Down Expand Up @@ -121,7 +121,7 @@ values:
sensitive_content: null
source: null
local_file.tfvars["globals"]:
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_base64: null
directory_permission: '0777'
file_permission: '0644'
Expand Down Expand Up @@ -1366,13 +1366,7 @@ counts:
outputs:
iam_principals:
domain: domain:example.org
gcp-billing-admins: group:gcp-billing-admins@example.org
gcp-devops: group:gcp-devops@example.org
gcp-network-admins: group:gcp-network-admins@example.org
gcp-organization-admins: group:fabric-fast-owners@google.com
gcp-secops-admins: group:gcp-secops-admins@example.org
gcp-security-admins: group:gcp-security-admins@example.org
gcp-support: group:gcp-support@example.org
projects: __missing__
subnet_ips:
dev:
Expand Down
10 changes: 2 additions & 8 deletions tests/fast/stages/s0_org_setup/customizations.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ values:
google_storage_bucket_object.tfvars["globals"]:
bucket: ft0-prod-iac-core-0-iac-outputs
cache_control: null
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_disposition: null
content_encoding: null
content_language: null
Expand Down Expand Up @@ -121,7 +121,7 @@ values:
sensitive_content: null
source: null
local_file.tfvars["globals"]:
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_base64: null
directory_permission: '0777'
file_permission: '0644'
Expand Down Expand Up @@ -1355,13 +1355,7 @@ counts:
outputs:
iam_principals:
domain: domain:example.org
gcp-billing-admins: group:gcp-billing-admins@example.org
gcp-devops: group:gcp-devops@example.org
gcp-network-admins: group:gcp-network-admins@example.org
gcp-organization-admins: group:fabric-fast-owners@google.com
gcp-secops-admins: group:gcp-secops-admins@example.org
gcp-security-admins: group:gcp-security-admins@example.org
gcp-support: group:gcp-support@example.org
projects: __missing__
subnet_ips:
dev:
Expand Down
10 changes: 2 additions & 8 deletions tests/fast/stages/s0_org_setup/hardened.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ values:
google_storage_bucket_object.tfvars["globals"]:
bucket: ft0-prod-iac-core-0-iac-outputs
cache_control: null
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_disposition: null
content_encoding: null
content_language: null
Expand Down Expand Up @@ -502,7 +502,7 @@ values:
sensitive_content: null
source: null
local_file.tfvars["globals"]:
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_base64: null
directory_permission: '0777'
file_permission: '0644'
Expand Down Expand Up @@ -8512,13 +8512,7 @@ counts:
outputs:
iam_principals:
domain: domain:example.org
gcp-billing-admins: group:gcp-billing-admins@example.org
gcp-devops: group:gcp-devops@example.org
gcp-network-admins: group:gcp-network-admins@example.org
gcp-organization-admins: group:fabric-fast-owners@google.com
gcp-secops-admins: group:gcp-secops-admins@example.org
gcp-security-admins: group:gcp-security-admins@example.org
gcp-support: group:gcp-support@example.org
projects: __missing__
subnet_ips: {}
subnet_self_links: {}
Expand Down
10 changes: 2 additions & 8 deletions tests/fast/stages/s0_org_setup/simple.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ values:
google_storage_bucket_object.tfvars["globals"]:
bucket: ft0-prod-iac-core-0-iac-outputs
cache_control: null
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_disposition: null
content_encoding: null
content_language: null
Expand Down Expand Up @@ -502,7 +502,7 @@ values:
sensitive_content: null
source: null
local_file.tfvars["globals"]:
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_base64: null
directory_permission: '0777'
file_permission: '0644'
Expand Down Expand Up @@ -2933,13 +2933,7 @@ counts:
outputs:
iam_principals:
domain: domain:example.org
gcp-billing-admins: group:gcp-billing-admins@example.org
gcp-devops: group:gcp-devops@example.org
gcp-network-admins: group:gcp-network-admins@example.org
gcp-organization-admins: group:fabric-fast-owners@google.com
gcp-secops-admins: group:gcp-secops-admins@example.org
gcp-security-admins: group:gcp-security-admins@example.org
gcp-support: group:gcp-support@example.org
projects: __missing__
subnet_ips: {}
subnet_self_links: {}
Expand Down
10 changes: 2 additions & 8 deletions tests/fast/stages/s0_org_setup/starter-gcd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ values:
google_storage_bucket_object.tfvars["globals"]:
bucket: ft0-prod-iac-core-0-iac-outputs
cache_control: null
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_disposition: null
content_encoding: null
content_language: null
Expand Down Expand Up @@ -173,7 +173,7 @@ values:
sensitive_content: null
source: null
local_file.tfvars["globals"]:
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-billing-admins":"group:gcp-billing-admins@example.org","gcp-devops":"group:gcp-devops@example.org","gcp-network-admins":"group:gcp-network-admins@example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com","gcp-secops-admins":"group:gcp-secops-admins@example.org","gcp-security-admins":"group:gcp-security-admins@example.org","gcp-support":"group:gcp-support@example.org"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content: '{"billing_account":{"id":"012345-012345-012345"},"groups":{"domain":"domain:example.org","gcp-organization-admins":"group:fabric-fast-owners@google.com"},"organization":{"customer_id":"abcd123456","domain":"example.org","id":"1234567890"},"prefix":"ft0","universe":null}'
content_base64: null
directory_permission: '0777'
file_permission: '0644'
Expand Down Expand Up @@ -1390,13 +1390,7 @@ counts:
outputs:
iam_principals:
domain: domain:example.org
gcp-billing-admins: group:gcp-billing-admins@example.org
gcp-devops: group:gcp-devops@example.org
gcp-network-admins: group:gcp-network-admins@example.org
gcp-organization-admins: group:fabric-fast-owners@google.com
gcp-secops-admins: group:gcp-secops-admins@example.org
gcp-security-admins: group:gcp-security-admins@example.org
gcp-support: group:gcp-support@example.org
projects: __missing__
subnet_ips:
dev:
Expand Down
Loading