switch to local module refs in stage0
This commit is contained in:
parent
941d862cfa
commit
bc50e9368a
|
@ -17,7 +17,7 @@
|
|||
# tfdoc:file:description Automation project and resources.
|
||||
|
||||
module "automation-project" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/project?ref=v12.0.0"
|
||||
source = "../../../modules/project"
|
||||
billing_account = var.billing_account.id
|
||||
name = "iac-core-0"
|
||||
parent = "organizations/${var.organization.id}"
|
||||
|
@ -68,7 +68,7 @@ module "automation-project" {
|
|||
# this stage's bucket and service account
|
||||
|
||||
module "automation-tf-bootstrap-gcs" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/gcs?ref=v12.0.0"
|
||||
source = "../../../modules/gcs"
|
||||
project_id = module.automation-project.project_id
|
||||
name = "iac-core-bootstrap-0"
|
||||
prefix = local.prefix
|
||||
|
@ -77,7 +77,7 @@ module "automation-tf-bootstrap-gcs" {
|
|||
}
|
||||
|
||||
module "automation-tf-bootstrap-sa" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/iam-service-account?ref=v12.0.0"
|
||||
source = "../../../modules/iam-service-account"
|
||||
project_id = module.automation-project.project_id
|
||||
name = "bootstrap-0"
|
||||
description = "Terraform organization bootstrap service account."
|
||||
|
@ -87,7 +87,7 @@ module "automation-tf-bootstrap-sa" {
|
|||
# resource hierarchy stage's bucket and service account
|
||||
|
||||
module "automation-tf-resman-gcs" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/gcs?ref=v12.0.0"
|
||||
source = "../../../modules/gcs"
|
||||
project_id = module.automation-project.project_id
|
||||
name = "iac-core-resman-0"
|
||||
prefix = local.prefix
|
||||
|
@ -99,7 +99,7 @@ module "automation-tf-resman-gcs" {
|
|||
}
|
||||
|
||||
module "automation-tf-resman-sa" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/iam-service-account?ref=v12.0.0"
|
||||
source = "../../../modules/iam-service-account"
|
||||
project_id = module.automation-project.project_id
|
||||
name = "resman-0"
|
||||
description = "Terraform organization bootstrap service account."
|
||||
|
|
|
@ -33,7 +33,7 @@ moved {
|
|||
}
|
||||
|
||||
module "billing-export-project" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/project?ref=v12.0.0"
|
||||
source = "../../../modules/project"
|
||||
count = local.billing_org ? 1 : 0
|
||||
billing_account = var.billing_account.id
|
||||
name = "billing-export-0"
|
||||
|
@ -58,7 +58,7 @@ moved {
|
|||
}
|
||||
|
||||
module "billing-export-dataset" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/bigquery-dataset?ref=v12.0.0"
|
||||
source = "../../../modules/bigquery-dataset"
|
||||
count = local.billing_org ? 1 : 0
|
||||
project_id = module.billing-export-project.0.project_id
|
||||
id = "billing_export"
|
||||
|
@ -68,7 +68,7 @@ module "billing-export-dataset" {
|
|||
# billing account in a different org
|
||||
|
||||
module "billing-organization-ext" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/organization?ref=v12.0.0"
|
||||
source = "../../../modules/organization"
|
||||
count = local.billing_org_ext ? 1 : 0
|
||||
organization_id = "organizations/${var.billing_account.organization_id}"
|
||||
iam_additive = {
|
||||
|
|
|
@ -21,7 +21,7 @@ locals {
|
|||
}
|
||||
|
||||
module "log-export-project" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/project?ref=v12.0.0"
|
||||
source = "../../../modules/project"
|
||||
name = "audit-logs-0"
|
||||
parent = "organizations/${var.organization.id}"
|
||||
prefix = local.prefix
|
||||
|
@ -42,7 +42,7 @@ module "log-export-project" {
|
|||
# one log export per type, with conditionals to skip those not needed
|
||||
|
||||
module "log-export-dataset" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/bigquery-dataset?ref=v12.0.0"
|
||||
source = "../../../modules/bigquery-dataset"
|
||||
count = contains(local.log_types, "bigquery") ? 1 : 0
|
||||
project_id = module.log-export-project.project_id
|
||||
id = "audit_export"
|
||||
|
@ -50,7 +50,7 @@ module "log-export-dataset" {
|
|||
}
|
||||
|
||||
module "log-export-gcs" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/gcs?ref=v12.0.0"
|
||||
source = "../../../modules/gcs"
|
||||
count = contains(local.log_types, "storage") ? 1 : 0
|
||||
project_id = module.log-export-project.project_id
|
||||
name = "audit-logs-0"
|
||||
|
@ -58,7 +58,7 @@ module "log-export-gcs" {
|
|||
}
|
||||
|
||||
module "log-export-logbucket" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/logging-bucket?ref=v12.0.0"
|
||||
source = "../../../modules/logging-bucket"
|
||||
count = contains(local.log_types, "logging") ? 1 : 0
|
||||
parent_type = "project"
|
||||
parent = module.log-export-project.project_id
|
||||
|
@ -66,7 +66,7 @@ module "log-export-logbucket" {
|
|||
}
|
||||
|
||||
module "log-export-pubsub" {
|
||||
source = "github.com/terraform-google-modules/cloud-foundation-fabric//modules/pubsub?ref=v12.0.0"
|
||||
source = "../../../modules/pubsub"
|
||||
for_each = toset([for k, v in var.log_sinks : k if v == "pubsub"])
|
||||
project_id = module.log-export-project.project_id
|
||||
name = "audit-logs-${each.key}"
|
||||
|
|
Loading…
Reference in New Issue