-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
locals.tf
51 lines (48 loc) · 977 Bytes
/
locals.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
# Terraform Local Values
# https://www.terraform.io/docs/language/values/locals.html
locals {
network = "projects/${var.host_project_id}/global/networks/${var.network}"
# These flags are required for CIS GCP v1.3.0 compliance
postgres_database_flags = concat([
{
name = "cloudsql.enable_pgaudit"
value = "on"
},
{
name = "log_checkpoints"
value = "on"
},
{
name = "log_connections"
value = "on"
},
{
name = "log_disconnections"
value = "on"
},
{
name = "log_hostname"
value = "on"
},
{
name = "log_lock_waits"
value = "on"
},
{
name = "log_min_error_statement"
value = "error"
},
{
name = "log_min_duration_statement"
value = "-1"
},
{
name = "log_min_messages"
value = "error"
},
{
name = "log_statement"
value = "ddl"
}
], var.postgres_database_flags)
}