Add support for quotas to project-factory module (#3242)
* Add support for quotas to project-factory module * Updated embeded definition in net-vpc-factory
This commit is contained in:
@@ -45,4 +45,5 @@ module "projects" {
|
||||
iam_by_principals_additive = each.value.iam_by_principals_additive
|
||||
org_policies = each.value.org_policies
|
||||
project_reuse = each.value.project_reuse
|
||||
quotas = each.value.quotas
|
||||
}
|
||||
|
||||
@@ -302,6 +302,7 @@ locals {
|
||||
try(v.logging_data_access, null),
|
||||
local.__projects_config.data_defaults.logging_data_access
|
||||
)
|
||||
quotas = try(v.quotas, {})
|
||||
})
|
||||
}
|
||||
# tflint-ignore: terraform_unused_declarations
|
||||
|
||||
@@ -137,6 +137,9 @@
|
||||
},
|
||||
"iam_by_principals_additive": {
|
||||
"$ref": "#/$defs/iamByPrincipals"
|
||||
},
|
||||
"quotas": {
|
||||
"$ref": "#/$defs/quotas"
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -1498,6 +1501,59 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"quotas": {
|
||||
"title": "Quotas",
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"patternProperties": {
|
||||
"^[a-zA-Z0-9_-]+$": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"service",
|
||||
"quota_id",
|
||||
"preferred_value"
|
||||
],
|
||||
"properties": {
|
||||
"service": {
|
||||
"type": "string"
|
||||
},
|
||||
"quota_id": {
|
||||
"type": "string"
|
||||
},
|
||||
"preferred_value": {
|
||||
"type": "number"
|
||||
},
|
||||
"dimensions": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"justification": {
|
||||
"type": "string"
|
||||
},
|
||||
"contact_email": {
|
||||
"type": "string"
|
||||
},
|
||||
"annotations": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"ignore_safety_checks": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"QUOTA_DECREASE_BELOW_USAGE",
|
||||
"QUOTA_DECREASE_PERCENTAGE_TOO_HIGH",
|
||||
"QUOTA_SAFETY_CHECK_UNSPECIFIED"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -302,6 +302,7 @@ locals {
|
||||
try(v.logging_data_access, null),
|
||||
local.__projects_config.data_defaults.logging_data_access
|
||||
)
|
||||
quotas = try(v.quotas, {})
|
||||
})
|
||||
}
|
||||
# tflint-ignore: terraform_unused_declarations
|
||||
|
||||
@@ -121,6 +121,7 @@ module "projects" {
|
||||
perimeter_bridges = each.value.vpc_sc.perimeter_bridges
|
||||
is_dry_run = each.value.vpc_sc.is_dry_run
|
||||
}
|
||||
quotas = each.value.quotas
|
||||
}
|
||||
|
||||
module "projects-iam" {
|
||||
|
||||
@@ -197,6 +197,59 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"quotas": {
|
||||
"title": "Quotas",
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"patternProperties": {
|
||||
"^[a-zA-Z0-9_-]+$": {
|
||||
"type": "object",
|
||||
"additionalProperties": false,
|
||||
"required": [
|
||||
"service",
|
||||
"quota_id",
|
||||
"preferred_value"
|
||||
],
|
||||
"properties": {
|
||||
"service": {
|
||||
"type": "string"
|
||||
},
|
||||
"quota_id": {
|
||||
"type": "string"
|
||||
},
|
||||
"preferred_value": {
|
||||
"type": "number"
|
||||
},
|
||||
"dimensions": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"justification": {
|
||||
"type": "string"
|
||||
},
|
||||
"contact_email": {
|
||||
"type": "string"
|
||||
},
|
||||
"annotations": {
|
||||
"type": "object",
|
||||
"additionalProperties": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"ignore_safety_checks": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"QUOTA_DECREASE_BELOW_USAGE",
|
||||
"QUOTA_DECREASE_PERCENTAGE_TOO_HIGH",
|
||||
"QUOTA_SAFETY_CHECK_UNSPECIFIED"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"parent": {
|
||||
"type": "string"
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user