From 01828479bef783684a6dcf4c650fcac00eb7f18e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Huss?= Date: Sun, 15 Oct 2023 17:52:56 +0200 Subject: [PATCH] fix --- apps/dbgate/configs.tf | 10 +++++ apps/dbgate/index.yaml | 100 ++++++++++++++++++++--------------------- 2 files changed, 60 insertions(+), 50 deletions(-) diff --git a/apps/dbgate/configs.tf b/apps/dbgate/configs.tf index b32ca4a..fc9eba1 100644 --- a/apps/dbgate/configs.tf +++ b/apps/dbgate/configs.tf @@ -87,3 +87,13 @@ data "kubernetes_secret_v1" "mongos" { namespace = "${var.mongo[count.index].namespace}" } } + +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" +} diff --git a/apps/dbgate/index.yaml b/apps/dbgate/index.yaml index 0aebfea..d226a59 100644 --- a/apps/dbgate/index.yaml +++ b/apps/dbgate/index.yaml @@ -35,40 +35,6 @@ options: type: string type: object type: array - issuer: - default: letsencrypt-prod - examples: - - letsencrypt-prod - type: string - maria: - default: [] - examples: - - [] - items: - properties: - dbname: - default: '' - type: string - name: - default: '' - type: string - namespace: - default: '' - type: string - secret: - properties: - key: - default: '' - type: string - name: - default: '' - type: string - type: object - username: - default: '' - type: string - type: object - type: array images: default: dbgate: @@ -108,11 +74,6 @@ options: type: string type: object type: object - ingress-class: - default: traefik - examples: - - traefik - type: string storage: default: accessMode: ReadWriteOnce @@ -140,26 +101,50 @@ options: - Block type: string type: object + ingress-class: + default: traefik + examples: + - traefik + type: string domain: default: your-company examples: - your-company type: string - sub-domain: - default: dbgate - examples: - - dbgate - type: string domain-name: default: your_company.com examples: - your_company.com type: string - app-group: - default: dev + maria: + default: [] examples: - - dev - type: string + - [] + items: + properties: + dbname: + default: '' + type: string + name: + default: '' + type: string + namespace: + default: '' + type: string + secret: + properties: + key: + default: '' + type: string + name: + default: '' + type: string + type: object + username: + default: '' + type: string + type: object + type: array mongo: default: [] examples: @@ -189,6 +174,21 @@ options: type: string type: object type: array + sub-domain: + default: dbgate + examples: + - dbgate + type: string + issuer: + default: letsencrypt-prod + examples: + - letsencrypt-prod + type: string + app-group: + default: dev + examples: + - dev + type: string dependencies: - dist: null category: share @@ -201,7 +201,7 @@ providers: authentik: true kubectl: true postgresql: null - restapi: null - http: null + restapi: true + http: true gitea: null tfaddtype: null