This commit is contained in:
2024-05-29 17:16:33 +02:00
parent 3dfe5b4a69
commit 2c671da3f8
11 changed files with 113 additions and 241 deletions

View File

@@ -103,4 +103,4 @@ providers:
restapi: true
http: true
gitea: null
tfaddtype: null
tfaddtype: true

View File

@@ -1,5 +1,5 @@
locals {
sorted-namespaces = reverse(distinct(sort(var.namespaces)))
sorted-namespaces = reverse(distinct(sort(concat(var.namespaces,var.detected.namespaces))))
}
resource "kubectl_manifest" "gramo_sa" {
yaml_body = <<-EOF

7
apps/gramo/template.rhai Normal file
View File

@@ -0,0 +1,7 @@
const DEST=dest;
const DOMAIN = config.domain;
fn post_template() {
save_to_tf(`${global::DEST}/detected.tf`, "detected", #{
namespaces: list_namespace().items.filter(|ns| ns.metadata.name.starts_with(`${global::DOMAIN}-`)).map(|ns| ns.metadata.name)+[global::DOMAIN]
});
}