Add more validations to linter

- Ensure all variables and outputs are sorted
- Ensure all variables and outputs have a description
- Add data-solutions/data-platform-foundations to linter

Fix all modules to follow these new conventions.
This commit is contained in:
Julio Castillo
2021-10-08 18:26:04 +02:00
parent 49a1999bac
commit 1d13e3e624
84 changed files with 989 additions and 941 deletions

View File

@@ -13,6 +13,21 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
output "firewall_policies" {
description = "Map of firewall policy resources created in this folder."
value = {
for name, _ in var.firewall_policies :
name => google_compute_organization_security_policy.policy[name]
}
}
output "firewall_policy_id" {
description = "Map of firewall policy ids created in this folder."
value = {
for name, _ in var.firewall_policies :
name => google_compute_organization_security_policy.policy[name].id
}
}
output "folder" {
description = "Folder resource."
@@ -34,22 +49,6 @@ output "name" {
value = local.folder.display_name
}
output "firewall_policies" {
description = "Map of firewall policy resources created in this folder."
value = {
for name, _ in var.firewall_policies :
name => google_compute_organization_security_policy.policy[name]
}
}
output "firewall_policy_id" {
description = "Map of firewall policy ids created in this folder."
value = {
for name, _ in var.firewall_policies :
name => google_compute_organization_security_policy.policy[name].id
}
}
output "sink_writer_identities" {
description = "Writer identities created for each sink."
value = {

View File

@@ -66,6 +66,12 @@ variable "id" {
default = null
}
variable "logging_exclusions" {
description = "Logging exclusions for this folder in the form {NAME -> FILTER}."
type = map(string)
default = {}
}
variable "logging_sinks" {
description = "Logging sinks to create for this folder."
type = map(object({
@@ -80,12 +86,6 @@ variable "logging_sinks" {
default = {}
}
variable "logging_exclusions" {
description = "Logging exclusions for this folder in the form {NAME -> FILTER}."
type = map(string)
default = {}
}
variable "name" {
description = "Folder name."
type = string