Added support for private apis

This commit is contained in:
2025-06-02 01:42:17 +02:00
parent b0162abb88
commit 54f7e5536a
21 changed files with 527 additions and 244 deletions
@@ -29,13 +29,20 @@ locals {
upstream = v.upstream
tls = v.tls
fqdn = join(" ", v.fqdn)
auth = length([for l in v.locations : true if l.private]) > 0
locations = [for l in v.locations : {
path = l.path
headers = merge(l.headers, coalesce(v.default_headers, local.default_headers))
path = l.path
headers = merge(l.headers, coalesce(v.default_headers, local.default_headers))
private = l.private
upstream = l.upstream
rewrite = l.rewrite
}]
custom_snippet = v.custom_snippet
}))
}
services_config_checksum = sha256(jsonencode(local.services_config))
auth_script = file("${path.module}/resources/auth/auth_server.py")
auth_script_checksum = sha256(local.auth_script)
}