From f1721100b81c4f4fb1dcb59854c90af140c51de5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Huss?= Date: Wed, 18 Oct 2023 17:40:21 +0200 Subject: [PATCH] fix --- apps/dbgate/application.tf | 6 + apps/dbgate/index.yaml | 210 +++++++++++++++---------------- modules/application/providers.tf | 8 ++ modules/ingress/providers.tf | 9 ++ 4 files changed, 128 insertions(+), 105 deletions(-) create mode 100644 modules/application/providers.tf create mode 100644 modules/ingress/providers.tf diff --git a/apps/dbgate/application.tf b/apps/dbgate/application.tf index d9db925..a136f01 100644 --- a/apps/dbgate/application.tf +++ b/apps/dbgate/application.tf @@ -31,6 +31,9 @@ module "ingress" { "number" = 80 } } + providers = { + kubectl = kubectl + } } module "application" { @@ -42,6 +45,9 @@ module "application" { domain-name = var.domain-name icon = "logo192.png" protocol_provider = var.use-oauth?module.oauth2.provider-id:module.forward.provider-id + providers = { + authentik = authentik + } } module "oauth2" { diff --git a/apps/dbgate/index.yaml b/apps/dbgate/index.yaml index f905112..be461b7 100644 --- a/apps/dbgate/index.yaml +++ b/apps/dbgate/index.yaml @@ -6,60 +6,21 @@ metadata: name: dbgate description: null options: - domain: - default: your-company + sub-domain: + default: dbgate examples: - - your-company + - dbgate type: string - use-oauth: - default: false - examples: - - false - type: boolean - issuer: - default: letsencrypt-prod - examples: - - letsencrypt-prod - type: string - ingress-class: - default: traefik - examples: - - traefik - type: string - pg: - 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 domain-name: default: your_company.com examples: - your_company.com type: string + domain: + default: your-company + examples: + - your-company + type: string maria: default: [] examples: @@ -89,35 +50,33 @@ options: type: string type: object type: array - mongo: - default: [] + storage: + default: + accessMode: ReadWriteOnce + size: 1Gi + type: Filesystem 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 + - accessMode: ReadWriteOnce + size: 1Gi + type: Filesystem + properties: + accessMode: + default: ReadWriteOnce + enum: + - ReadWriteOnce + - ReadOnlyMany + - ReadWriteMany + type: string + size: + default: 1Gi + type: string + type: + default: Filesystem + enum: + - Filesystem + - Block + type: string + type: object images: default: dbgate: @@ -157,43 +116,84 @@ options: type: string type: object type: object - storage: - default: - accessMode: ReadWriteOnce - size: 1Gi - type: Filesystem + ingress-class: + default: traefik examples: - - accessMode: ReadWriteOnce - size: 1Gi - type: Filesystem - properties: - accessMode: - default: ReadWriteOnce - enum: - - ReadWriteOnce - - ReadOnlyMany - - ReadWriteMany - type: string - size: - default: 1Gi - type: string - type: - default: Filesystem - enum: - - Filesystem - - Block - type: string - type: object - sub-domain: - default: dbgate - examples: - - dbgate + - traefik type: string + mongo: + 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 + issuer: + default: letsencrypt-prod + examples: + - letsencrypt-prod + type: string + pg: + 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 app-group: default: dev examples: - dev type: string + use-oauth: + default: false + examples: + - false + type: boolean dependencies: - dist: null category: share diff --git a/modules/application/providers.tf b/modules/application/providers.tf new file mode 100644 index 0000000..0e00fa9 --- /dev/null +++ b/modules/application/providers.tf @@ -0,0 +1,8 @@ +terraform { + required_providers { + authentik = { + source = "goauthentik/authentik" + version = "~> 2023.5.0" + } + } +} diff --git a/modules/ingress/providers.tf b/modules/ingress/providers.tf new file mode 100644 index 0000000..d959f39 --- /dev/null +++ b/modules/ingress/providers.tf @@ -0,0 +1,9 @@ + +terraform { + required_providers { + kubectl = { + source = "gavinbunney/kubectl" + version = "~> 1.14.0" + } + } +}