change to publish only the enabled one
Gitea Actions Demo / Explore-Gitea-Actions (push) Failing after 55s
Gitea Actions Demo / Explore-Gitea-Actions (push) Failing after 55s
This commit is contained in:
@@ -19,22 +19,6 @@ variable "nginx_sites" {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
locals {
|
|
||||||
template = templatefile("websites_terraform.json.tftpl", {
|
|
||||||
map_of_params = var.nginx_sites
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
resource "local_file" "nginx" {
|
|
||||||
content = templatefile("websites_terraform.json.tftpl", {
|
|
||||||
map_of_params = var.nginx_sites })
|
|
||||||
filename = "/tmp/test.tryton.geeraert.eu.conf"
|
|
||||||
file_permission = "0600"
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
resource "kubernetes_config_map" "websites_configmap" {
|
resource "kubernetes_config_map" "websites_configmap" {
|
||||||
metadata {
|
metadata {
|
||||||
name = "sites-terraform"
|
name = "sites-terraform"
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
%{ for key, value in map_of_params}
|
%{ for key, value in map_of_params }
|
||||||
|
%{ if value.enabled}
|
||||||
{
|
{
|
||||||
"${key}": {
|
"${key}": {
|
||||||
"service": "${value.service}"
|
"service": "${value.service}"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
%{ endif }
|
||||||
%{ endfor ~}
|
%{ endfor ~}
|
||||||
|
|||||||
Reference in New Issue
Block a user