-
Notifications
You must be signed in to change notification settings - Fork 147
/
Copy pathvariables.tf
148 lines (128 loc) · 4.09 KB
/
variables.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
/**
* Copyright 2020 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/******************************************
Required variables
*******************************************/
variable "parent_folder" {
description = "GCP parent folder ID in the form folders/{id}"
default = ""
type = string
}
variable "org_id" {
description = "GCP Organization ID"
type = string
}
variable "billing_account" {
description = "The ID of the billing account to associate projects with."
type = string
}
variable "group_org_admins" {
description = "Google Group for GCP Organization Administrators"
type = string
}
variable "group_billing_admins" {
description = "Google Group for GCP Billing Administrators"
type = string
}
variable "default_region" {
description = "Default region to create resources where applicable."
type = string
default = "us-central1"
}
/******************************************
Optional variables
*******************************************/
variable "project_labels" {
description = "Labels to apply to the project."
type = map(string)
default = {}
}
variable "project_prefix" {
description = "Name prefix to use for projects created."
default = "cft"
type = string
}
variable "activate_apis" {
description = "List of APIs to enable in the seed project."
type = list(string)
default = [
"serviceusage.googleapis.com",
"servicenetworking.googleapis.com",
"compute.googleapis.com",
"logging.googleapis.com",
"bigquery.googleapis.com",
"cloudresourcemanager.googleapis.com",
"cloudbilling.googleapis.com",
"iam.googleapis.com",
"admin.googleapis.com",
"appengine.googleapis.com",
"storage-api.googleapis.com",
"monitoring.googleapis.com"
]
}
variable "sa_org_iam_permissions" {
description = "List of permissions granted to Terraform service account across the GCP organization."
type = list(string)
default = [
"roles/billing.user",
"roles/compute.networkAdmin",
"roles/compute.xpnAdmin",
"roles/iam.securityAdmin",
"roles/iam.serviceAccountAdmin",
"roles/logging.configWriter",
"roles/orgpolicy.policyAdmin",
"roles/resourcemanager.folderAdmin",
"roles/resourcemanager.organizationViewer",
]
}
variable "sa_enable_impersonation" {
description = "Allow org_admins group to impersonate service account & enable APIs required."
type = bool
default = false
}
variable "grant_billing_user" {
description = "Grant roles/billing.user role to CFT service account"
type = bool
default = true
}
variable "storage_bucket_labels" {
description = "Labels to apply to the storage bucket."
type = map(string)
default = {}
}
variable "org_admins_org_iam_permissions" {
description = "List of permissions granted to the group supplied in group_org_admins variable across the GCP organization."
type = list(string)
default = [
"roles/billing.user",
"roles/resourcemanager.organizationAdmin"
]
}
variable "folder_id" {
description = "The ID of a folder to host this project"
type = string
default = ""
}
variable "org_project_creators" {
description = "Additional list of members to have project creator role accross the organization. Prefix of group: user: or serviceAccount: is required."
type = list(string)
default = []
}
variable "skip_gcloud_download" {
description = "Whether to skip downloading gcloud (assumes gcloud is already available outside the module)"
type = bool
default = true
}