From 284ff31b7dde09d3200579ce7f5ade11cf8db324 Mon Sep 17 00:00:00 2001 From: SeanOMik Date: Sun, 22 Oct 2023 12:25:20 -0400 Subject: [PATCH] fix(postgresql): fix crash loop --- .../database/postgresql/helm-release.yaml | 20 +++++++++++++++++++ .../postgresql/pgadmin4/helm-release.yaml | 10 ++++++++-- .../postgresql/pgadmin4/kustomization.yaml | 1 + .../apps/database/postgresql/pgsql.sops.yaml | 6 +++--- 4 files changed, 32 insertions(+), 5 deletions(-) diff --git a/cluster/apps/database/postgresql/helm-release.yaml b/cluster/apps/database/postgresql/helm-release.yaml index 1c51a1c..db53425 100644 --- a/cluster/apps/database/postgresql/helm-release.yaml +++ b/cluster/apps/database/postgresql/helm-release.yaml @@ -36,6 +36,26 @@ spec: enabled: true runAsUser: 10000 + extendedConfiguration: |- + huge_pages = off + extraVolumeMounts: + - name: pg-sample-config + mountPath: /opt/bitnami/postgresql/share/postgresql.conf.sample + subPath: postgresql.conf.sample + extraVolumes: + - configMap: + name: pg-sample-config + name: pg-sample-config + + extraDeploy: + - apiVersion: v1 + kind: ConfigMap + metadata: + name: pg-sample-config + data: + postgresql.conf.sample: |- + huge_pages = off + readReplicas: containerSecurityContext: enabled: true diff --git a/cluster/apps/database/postgresql/pgadmin4/helm-release.yaml b/cluster/apps/database/postgresql/pgadmin4/helm-release.yaml index 843c4e4..d132f01 100644 --- a/cluster/apps/database/postgresql/pgadmin4/helm-release.yaml +++ b/cluster/apps/database/postgresql/pgadmin4/helm-release.yaml @@ -8,7 +8,7 @@ spec: chart: spec: chart: pgadmin4 - version: 1.14.x + version: "1.18.2" sourceRef: kind: HelmRepository name: runix-charts @@ -20,7 +20,7 @@ spec: cert-manager.io/cluster-issuer: letsencrypt-production traefik.ingress.kubernetes.io/router.entrypoints: websecure hosts: - - host: &host pgadm.database.${SECRET_DOMAIN} + - host: &host pgadm.${SECRET_NEW_DOMAIN} paths: - path: "/" pathType: Prefix @@ -38,5 +38,11 @@ spec: # enabled: true # allowPrivilegeEscalation: false +# envVarsFromConfigMaps: +# - pgadmin4-secret + + persistentVolume: + enabled: false + volumePermissions: enabled: true \ No newline at end of file diff --git a/cluster/apps/database/postgresql/pgadmin4/kustomization.yaml b/cluster/apps/database/postgresql/pgadmin4/kustomization.yaml index 14a2c31..a83bec5 100644 --- a/cluster/apps/database/postgresql/pgadmin4/kustomization.yaml +++ b/cluster/apps/database/postgresql/pgadmin4/kustomization.yaml @@ -1,5 +1,6 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization resources: +- ./pgadmin4.sops.yaml - ./helm-repository.yaml - ./helm-release.yaml \ No newline at end of file diff --git a/cluster/apps/database/postgresql/pgsql.sops.yaml b/cluster/apps/database/postgresql/pgsql.sops.yaml index 5d2fd8a..9c1b403 100644 --- a/cluster/apps/database/postgresql/pgsql.sops.yaml +++ b/cluster/apps/database/postgresql/pgsql.sops.yaml @@ -13,8 +13,8 @@ sops: azure_kv: [] hc_vault: [] age: [] - lastmodified: "2023-04-07T01:57:23Z" - mac: ENC[AES256_GCM,data:wvjHgGOMyuVpy4klW5/aO434NKABQJc0907BIwLOXMxSOuIsedAeRhCWdi70IJfv5m8gIcRCb/jWVtDgQePd6CALglH72VlA3NiZI5EQrdBLQUmpGSglLNScrLDOjqNrXG/UgmikATskO5R0vl/203jt1S4OupuEHiPqPRHSSdc=,iv:qHHpufOzzjk8NCuldShenJbC1BlzhMpy4Tz2wWBolvw=,tag:HpoB7PM1gZfv6qfun7ucRw==,type:str] + lastmodified: "2023-10-22T16:25:15Z" + mac: ENC[AES256_GCM,data:uWVPfKwPpR212js7f2RnCzEsMnxk2JpGPcf2L5i4gJCddJCrRJkdhjWGyVVpp/ociP3JLRTI95+WSEUH0KkPZpY1ptQevCVsUemRytOCtBlR0yR4qsBwEisSu8m4B5dbAYsqlXAndrBNL2WGB7uBv+ILgNxkhlN58unseSWJBDM=,iv:e7QyZSlhpyQ+A8OmV4p1848itIUxyam6CJOI9/N7DDY=,tag:N28mfrAjUTTYkly1hu0OhA==,type:str] pgp: - created_at: "2023-06-19T18:35:15Z" enc: | @@ -59,4 +59,4 @@ sops: -----END PGP MESSAGE----- fp: 687802D4DFD8AA82EA55666CF7DADAC782D7663D encrypted_regex: ^(data|stringData)$ - version: 3.7.3 + version: 3.8.0