chore(ci): add command to fmt testdata terraform files (#1042)
This commit is contained in:
parent
4552b14edd
commit
a81b7d49e7
9 changed files with 46 additions and 46 deletions
6
Makefile
6
Makefile
|
|
@ -14,8 +14,8 @@ lint-golangci-lint:
|
||||||
@$(SCRIPTS_BASE)/lint-golangci-lint.sh
|
@$(SCRIPTS_BASE)/lint-golangci-lint.sh
|
||||||
|
|
||||||
lint-tf:
|
lint-tf:
|
||||||
@echo "Linting examples"
|
@echo "Linting terraform files"
|
||||||
@terraform fmt -check -diff -recursive examples
|
@terraform fmt -check -diff -recursive
|
||||||
|
|
||||||
lint: lint-golangci-lint lint-tf
|
lint: lint-golangci-lint lint-tf
|
||||||
|
|
||||||
|
|
@ -30,7 +30,7 @@ build:
|
||||||
fmt:
|
fmt:
|
||||||
@gofmt -s -w .
|
@gofmt -s -w .
|
||||||
@go tool goimports -w .
|
@go tool goimports -w .
|
||||||
@cd $(ROOT_DIR)/examples && terraform fmt -recursive && cd $(ROOT_DIR)
|
@terraform fmt -diff -recursive
|
||||||
|
|
||||||
# TEST
|
# TEST
|
||||||
test:
|
test:
|
||||||
|
|
|
||||||
|
|
@ -27,7 +27,7 @@ data "stackit_image_v2" "filter_uefi_ubuntu" {
|
||||||
project_id = var.project_id
|
project_id = var.project_id
|
||||||
filter = {
|
filter = {
|
||||||
distro = "ubuntu"
|
distro = "ubuntu"
|
||||||
uefi = true
|
uefi = true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -35,9 +35,9 @@ data "stackit_image_v2" "name_regex_and_filter_rhel_9_1" {
|
||||||
project_id = var.project_id
|
project_id = var.project_id
|
||||||
name_regex = "^Red Hat Enterprise Linux 9.1$"
|
name_regex = "^Red Hat Enterprise Linux 9.1$"
|
||||||
filter = {
|
filter = {
|
||||||
distro = "rhel"
|
distro = "rhel"
|
||||||
version = "9.1"
|
version = "9.1"
|
||||||
uefi = true
|
uefi = true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -9,13 +9,13 @@ variable "routed" {}
|
||||||
variable "label" {}
|
variable "label" {}
|
||||||
|
|
||||||
resource "stackit_network" "network_prefix" {
|
resource "stackit_network" "network_prefix" {
|
||||||
project_id = var.project_id
|
project_id = var.project_id
|
||||||
name = var.name
|
name = var.name
|
||||||
ipv4_gateway = var.ipv4_gateway != "" ? var.ipv4_gateway : null
|
ipv4_gateway = var.ipv4_gateway != "" ? var.ipv4_gateway : null
|
||||||
no_ipv4_gateway = var.ipv4_gateway != "" ? null : true
|
no_ipv4_gateway = var.ipv4_gateway != "" ? null : true
|
||||||
ipv4_nameservers = [var.ipv4_nameserver_0, var.ipv4_nameserver_1]
|
ipv4_nameservers = [var.ipv4_nameserver_0, var.ipv4_nameserver_1]
|
||||||
ipv4_prefix = var.ipv4_prefix
|
ipv4_prefix = var.ipv4_prefix
|
||||||
routed = var.routed
|
routed = var.routed
|
||||||
labels = {
|
labels = {
|
||||||
"acc-test" : var.label
|
"acc-test" : var.label
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -24,8 +24,8 @@ variable "network_area_id" {}
|
||||||
# }
|
# }
|
||||||
|
|
||||||
resource "stackit_network" "network_prefix_length" {
|
resource "stackit_network" "network_prefix_length" {
|
||||||
project_id = var.project_id
|
project_id = var.project_id
|
||||||
name = var.name
|
name = var.name
|
||||||
# no_ipv4_gateway = true
|
# no_ipv4_gateway = true
|
||||||
ipv4_nameservers = [var.ipv4_nameserver_0, var.ipv4_nameserver_1]
|
ipv4_nameservers = [var.ipv4_nameserver_0, var.ipv4_nameserver_1]
|
||||||
ipv4_prefix_length = var.ipv4_prefix_length
|
ipv4_prefix_length = var.ipv4_prefix_length
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@ resource "stackit_volume" "volume_source" {
|
||||||
name = var.name
|
name = var.name
|
||||||
description = var.description
|
description = var.description
|
||||||
performance_class = var.performance_class
|
performance_class = var.performance_class
|
||||||
size = var.size
|
size = var.size
|
||||||
source = {
|
source = {
|
||||||
id = stackit_volume.volume_size.volume_id
|
id = stackit_volume.volume_size.volume_id
|
||||||
type = "volume"
|
type = "volume"
|
||||||
|
|
|
||||||
|
|
@ -35,23 +35,23 @@ resource "stackit_logme_instance" "instance" {
|
||||||
version = var.logme_version
|
version = var.logme_version
|
||||||
|
|
||||||
parameters = {
|
parameters = {
|
||||||
enable_monitoring = var.params_enable_monitoring
|
enable_monitoring = var.params_enable_monitoring
|
||||||
fluentd_tcp = var.params_fluentd_tcp
|
fluentd_tcp = var.params_fluentd_tcp
|
||||||
fluentd_tls = var.params_fluentd_tls
|
fluentd_tls = var.params_fluentd_tls
|
||||||
fluentd_tls_ciphers = var.params_fluentd_tls_ciphers
|
fluentd_tls_ciphers = var.params_fluentd_tls_ciphers
|
||||||
fluentd_tls_max_version = var.params_fluentd_tls_max_version
|
fluentd_tls_max_version = var.params_fluentd_tls_max_version
|
||||||
fluentd_tls_min_version = var.params_fluentd_tls_min_version
|
fluentd_tls_min_version = var.params_fluentd_tls_min_version
|
||||||
fluentd_tls_version = var.params_fluentd_tls_version
|
fluentd_tls_version = var.params_fluentd_tls_version
|
||||||
fluentd_udp = var.params_fluentd_udp
|
fluentd_udp = var.params_fluentd_udp
|
||||||
graphite = var.params_graphite
|
graphite = var.params_graphite
|
||||||
ism_deletion_after = var.params_ism_deletion_after
|
ism_deletion_after = var.params_ism_deletion_after
|
||||||
ism_jitter = var.params_ism_jitter
|
ism_jitter = var.params_ism_jitter
|
||||||
ism_job_interval = var.params_ism_job_interval
|
ism_job_interval = var.params_ism_job_interval
|
||||||
java_heapspace = var.params_java_heapspace
|
java_heapspace = var.params_java_heapspace
|
||||||
java_maxmetaspace = var.params_java_maxmetaspace
|
java_maxmetaspace = var.params_java_maxmetaspace
|
||||||
max_disk_threshold = var.params_max_disk_threshold
|
max_disk_threshold = var.params_max_disk_threshold
|
||||||
metrics_frequency = var.params_metrics_frequency
|
metrics_frequency = var.params_metrics_frequency
|
||||||
metrics_prefix = var.params_metrics_prefix
|
metrics_prefix = var.params_metrics_prefix
|
||||||
opensearch_tls_ciphers = [var.params_opensearch_tls_cipher1, var.params_opensearch_tls_cipher2]
|
opensearch_tls_ciphers = [var.params_opensearch_tls_cipher1, var.params_opensearch_tls_cipher2]
|
||||||
opensearch_tls_protocols = [var.params_opensearch_tls_protocol1, var.params_opensearch_tls_protocol2]
|
opensearch_tls_protocols = [var.params_opensearch_tls_protocol1, var.params_opensearch_tls_protocol2]
|
||||||
sgw_acl = var.params_sgw_acl
|
sgw_acl = var.params_sgw_acl
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,6 @@ resource "stackit_mariadb_instance" "instance" {
|
||||||
}
|
}
|
||||||
|
|
||||||
resource "stackit_mariadb_credential" "credential" {
|
resource "stackit_mariadb_credential" "credential" {
|
||||||
project_id = var.project_id
|
project_id = var.project_id
|
||||||
instance_id = stackit_mariadb_instance.instance.instance_id
|
instance_id = stackit_mariadb_instance.instance.instance_id
|
||||||
}
|
}
|
||||||
|
|
@ -129,18 +129,18 @@ resource "stackit_observability_instance" "instance" {
|
||||||
]
|
]
|
||||||
opsgenie_configs = [
|
opsgenie_configs = [
|
||||||
{
|
{
|
||||||
api_key = var.opsgenie_api_key
|
api_key = var.opsgenie_api_key
|
||||||
tags = var.opsgenie_api_tags
|
tags = var.opsgenie_api_tags
|
||||||
api_url = var.opsgenie_api_url
|
api_url = var.opsgenie_api_url
|
||||||
priority = var.opsgenie_priority
|
priority = var.opsgenie_priority
|
||||||
send_resolved = var.opsgenie_send_resolved
|
send_resolved = var.opsgenie_send_resolved
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
webhooks_configs = [
|
webhooks_configs = [
|
||||||
{
|
{
|
||||||
url = var.webhook_configs_url
|
url = var.webhook_configs_url
|
||||||
ms_teams = var.ms_teams
|
ms_teams = var.ms_teams
|
||||||
google_chat = var.google_chat
|
google_chat = var.google_chat
|
||||||
send_resolved = var.webhook_configs_send_resolved
|
send_resolved = var.webhook_configs_send_resolved
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -6,11 +6,11 @@ variable "suspended" {}
|
||||||
variable "region" {}
|
variable "region" {}
|
||||||
|
|
||||||
resource "stackit_scf_organization" "org" {
|
resource "stackit_scf_organization" "org" {
|
||||||
project_id = var.project_id
|
project_id = var.project_id
|
||||||
name = var.name
|
name = var.name
|
||||||
suspended = var.suspended
|
suspended = var.suspended
|
||||||
quota_id = var.quota_id
|
quota_id = var.quota_id
|
||||||
region = var.region
|
region = var.region
|
||||||
}
|
}
|
||||||
|
|
||||||
resource "stackit_scf_organization_manager" "orgmanager" {
|
resource "stackit_scf_organization_manager" "orgmanager" {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue