You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description = "Map of allowed IPs with descriptions"
63
+
type = map(string)
64
+
default = {
65
+
"1.2.3.4/32" = "Office IP"
66
+
"5.6.7.8/32" = "Home IP"
67
+
"10.0.0.0/24" = "Internal network"
68
+
}
69
+
}
70
+
71
+
resource "scaleway_rdb_acl" "main" {
72
+
instance_id = scaleway_rdb_instance.main.id
73
+
74
+
dynamic "acl_rules" {
75
+
for_each = var.allowed_ips
76
+
content {
77
+
ip = acl_rules.key
78
+
description = acl_rules.value
79
+
}
80
+
}
81
+
}
82
+
```
83
+
35
84
## Argument Reference
36
85
37
86
The following arguments are supported:
@@ -42,6 +91,8 @@ The following arguments are supported:
42
91
43
92
-`acl_rules` - A list of ACLs (structure is described below)
44
93
94
+
~> **Important:** The `scaleway_rdb_acl` resource replaces **all** ACL rules for the given instance. Multiple `scaleway_rdb_acl` resources targeting the same `instance_id` will conflict with each other. Use multiple `acl_rules` blocks within a single resource instead.
95
+
45
96
-`region` - (Defaults to [provider](../index.md#region)`region`) The [region](../guides/regions_and_zones.md#regions) in which the Database Instance should be created.
description = "Map of allowed IPs with descriptions"
63
+
type = map(string)
64
+
default = {
65
+
"1.2.3.4/32" = "Office IP"
66
+
"5.6.7.8/32" = "Home IP"
67
+
"10.0.0.0/24" = "Internal network"
68
+
}
69
+
}
70
+
71
+
resource "scaleway_rdb_acl" "main" {
72
+
instance_id = scaleway_rdb_instance.main.id
73
+
74
+
dynamic "acl_rules" {
75
+
for_each = var.allowed_ips
76
+
content {
77
+
ip = acl_rules.key
78
+
description = acl_rules.value
79
+
}
80
+
}
81
+
}
82
+
```
83
+
35
84
## Argument Reference
36
85
37
86
The following arguments are supported:
@@ -42,6 +91,8 @@ The following arguments are supported:
42
91
43
92
- `acl_rules` - A list of ACLs (structure is described below)
44
93
94
+
~> **Important:** The `scaleway_rdb_acl` resource replaces **all** ACL rules for the given instance. Multiple `scaleway_rdb_acl` resources targeting the same `instance_id` will conflict with each other. Use multiple `acl_rules` blocks within a single resource instead.
95
+
45
96
- `region` - (Defaults to [provider](../index.md#region) `region`) The [region](../guides/regions_and_zones.md#regions) in which the Database Instance should be created.
0 commit comments