fix
This commit is contained in:
80
apps/infisical/presentation.tf
Normal file
80
apps/infisical/presentation.tf
Normal file
@@ -0,0 +1,80 @@
|
||||
locals {
|
||||
dns_name = "${var.sub_domain}.${var.domain_name}"
|
||||
dns_names = [local.dns_name]
|
||||
icon = "icon.svg"
|
||||
request_headers = {
|
||||
"Content-Type" = "application/json"
|
||||
Authorization = "Bearer ${data.kubernetes_secret_v1.authentik.data["AUTHENTIK_BOOTSTRAP_TOKEN"]}"
|
||||
}
|
||||
}
|
||||
|
||||
module "service" {
|
||||
source = "git::https://git.solidite.fr/vynil/kydah-modules.git//service"
|
||||
component = var.component
|
||||
instance = var.instance
|
||||
namespace = var.namespace
|
||||
labels = local.common-labels
|
||||
targets = ["http"]
|
||||
providers = {
|
||||
kubectl = kubectl
|
||||
}
|
||||
}
|
||||
|
||||
module "ingress" {
|
||||
source = "git::https://git.solidite.fr/vynil/kydah-modules.git//ingress"
|
||||
component = ""
|
||||
instance = var.instance
|
||||
namespace = var.namespace
|
||||
issuer = var.issuer
|
||||
ingress_class = var.ingress_class
|
||||
labels = local.common-labels
|
||||
dns_names = local.dns_names
|
||||
middlewares = [module.forward.middleware]
|
||||
services = [module.service.default_definition]
|
||||
providers = {
|
||||
kubectl = kubectl
|
||||
}
|
||||
}
|
||||
|
||||
module "application" {
|
||||
source = "git::https://git.solidite.fr/vynil/kydah-modules.git//application"
|
||||
component = var.component
|
||||
instance = var.instance
|
||||
app_group = var.app_group
|
||||
dns_name = local.dns_name
|
||||
icon = local.icon
|
||||
protocol_provider = module.forward.provider-id
|
||||
providers = {
|
||||
authentik = authentik
|
||||
}
|
||||
}
|
||||
|
||||
provider "restapi" {
|
||||
uri = "http://authentik.${var.domain}-auth.svc/api/v3/"
|
||||
headers = local.request_headers
|
||||
create_method = "PATCH"
|
||||
update_method = "PATCH"
|
||||
destroy_method = "PATCH"
|
||||
write_returns_object = true
|
||||
id_attribute = "name"
|
||||
}
|
||||
|
||||
module "forward" {
|
||||
source = "git::https://git.solidite.fr/vynil/kydah-modules.git//forward"
|
||||
component = var.component
|
||||
instance = var.instance
|
||||
domain = var.domain
|
||||
namespace = var.namespace
|
||||
ingress_class = var.ingress_class
|
||||
labels = local.common-labels
|
||||
dns_names = local.dns_names
|
||||
service = module.service.default_definition
|
||||
icon = local.icon
|
||||
request_headers = local.request_headers
|
||||
providers = {
|
||||
restapi = restapi
|
||||
http = http
|
||||
kubectl = kubectl
|
||||
authentik = authentik
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user