From b06d54e5cadfa2158bb434b9b203a8ba4461e0ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mat=C3=A9o=20M=C3=A9vollon?= <38255502+matmut7@users.noreply.github.com> Date: Wed, 12 Jun 2024 11:23:59 +0200 Subject: [PATCH] chore: remove pgadmin for now (#344) --- .../templates/pgadmin.sealed-secret.yaml | 16 ---- .kontinuous/env/preprod/values.yaml | 96 ------------------- src/pgadmin/Dockerfile | 18 ---- src/pgadmin/primary_entrypoint.sh | 79 --------------- 4 files changed, 209 deletions(-) delete mode 100644 .kontinuous/env/preprod/templates/pgadmin.sealed-secret.yaml delete mode 100644 src/pgadmin/Dockerfile delete mode 100644 src/pgadmin/primary_entrypoint.sh diff --git a/.kontinuous/env/preprod/templates/pgadmin.sealed-secret.yaml b/.kontinuous/env/preprod/templates/pgadmin.sealed-secret.yaml deleted file mode 100644 index 34f5f6a5..00000000 --- a/.kontinuous/env/preprod/templates/pgadmin.sealed-secret.yaml +++ /dev/null @@ -1,16 +0,0 @@ -apiVersion: bitnami.com/v1alpha1 -kind: SealedSecret -metadata: - annotations: - sealedsecrets.bitnami.com/cluster-wide: 'true' - name: pgadmin -spec: - encryptedData: - PGADMIN_DEFAULT_PASSWORD: AgC4lnwAliiHTu4jrQtioJZRoDhtqytcC+iYSMUfEfbaij5sgwuc0yd4493HZyLRys4b4Hw5WHKNaRKW37bwHYXULuH0D5k6n4M6lWkt1n1EWt+uZHO1GUNMpAf17Fci30MTdXZyw+rgvfzpJns95Y+YCsiR+Xqcj9/C+RmotLgpgTxdXTUgMlQYNxEhCttFW8kqKcpmOkiuNHYig5srzNSUzy9udIkc8X5iuyZItatcN6mi/8GhLjbbWCTrwwB3mu8HlY/aHf8ioXrP77SFpSh/iccto1lNygMluZftomX7pPk/H1fsGL3DgOD4aLqNfxwo4UgMSEaBy73nEkI2V5lXzTQy8E7PKd37zt5JaJSnpvvp7rovytx4F6yZ8O49mx4Rjpaz5U1S3l3JV09K/jcuzvzx9MIIAQ49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LqzOHaMiI= - template: - metadata: - annotations: - sealedsecrets.bitnami.com/cluster-wide: 'true' - name: pgadmin - type: Opaque diff --git a/.kontinuous/env/preprod/values.yaml b/.kontinuous/env/preprod/values.yaml index 960c4af0..6ffd167c 100644 --- a/.kontinuous/env/preprod/values.yaml +++ b/.kontinuous/env/preprod/values.yaml @@ -130,99 +130,3 @@ pg-strapi: cnpg-cluster: backup: ~tpl~enabled: "false" - -pgadmin: - ~chart: app - ~needs: ["build-pgadmin"] - imagePackage: pgadmin - containerPort: 80 - probesPath: / - envFrom: - - secretRef: - name: pgadmin - - env: - - name: POSTGRES_DATABASE - valueFrom: - secretKeyRef: - name: pg-app - key: PGDATABASE - - name: POSTGRES_USER - valueFrom: - secretKeyRef: - name: pg-app - key: PGUSER - - name: POSTGRES_PASSWORD - valueFrom: - secretKeyRef: - name: pg-app - key: PGPASSWORD - - name: POSTGRES_HOST - valueFrom: - secretKeyRef: - name: pg-app - key: PGHOST - - name: POSTGRES_PORT - valueFrom: - secretKeyRef: - name: pg-app - key: PGPORT - - name: POSTGRES_DATABASE_2 - valueFrom: - secretKeyRef: - name: pg-n8n-app - key: PGDATABASE - - name: POSTGRES_USER_2 - valueFrom: - secretKeyRef: - name: pg-n8n-app - key: PGUSER - - name: POSTGRES_PASSWORD_2 - valueFrom: - secretKeyRef: - name: pg-n8n-app - key: PGPASSWORD - - name: POSTGRES_HOST_2 - valueFrom: - secretKeyRef: - name: pg-n8n-app - key: PGHOST - - name: POSTGRES_PORT_2 - valueFrom: - secretKeyRef: - name: pg-n8n-app - key: PGPORT - - name: POSTGRES_DATABASE_3 - valueFrom: - secretKeyRef: - name: pg-strapi-app - key: PGDATABASE - - name: POSTGRES_USER_3 - valueFrom: - secretKeyRef: - name: pg-strapi-app - key: PGUSER - - name: POSTGRES_PASSWORD_3 - valueFrom: - secretKeyRef: - name: pg-strapi-app - key: PGPASSWORD - - name: POSTGRES_HOST_3 - valueFrom: - secretKeyRef: - name: pg-strapi-app - key: PGHOST - - name: POSTGRES_PORT_3 - valueFrom: - secretKeyRef: - name: pg-strapi-app - key: PGPORT - -jobs: - ~chart: jobs - runs: - build-pgadmin: - use: build - with: - imagePackage: pgadmin - context: src/pgadmin diff --git a/src/pgadmin/Dockerfile b/src/pgadmin/Dockerfile deleted file mode 100644 index ceb1815c..00000000 --- a/src/pgadmin/Dockerfile +++ /dev/null @@ -1,18 +0,0 @@ -ARG BASE_VERSION=8.5 -FROM dpage/pgadmin4:${BASE_VERSION} - -ENV PGADMIN_CONFIG_SERVER_MODE="True" -ENV PGADMIN_CONFIG_MASTER_PASSWORD_REQUIRED="False" - -ENV POSTGRES_HOST="postgres" -ENV POSTGRES_PORT="5432" -ENV POSTGRES_DB="*" - -USER root -COPY primary_entrypoint.sh /primary_entrypoint.sh -RUN chmod +x /primary_entrypoint.sh && \ - touch /pgadmin4/servers.json && \ - chown pgadmin:root /pgadmin4/servers.json -USER 5050 - -ENTRYPOINT /primary_entrypoint.sh diff --git a/src/pgadmin/primary_entrypoint.sh b/src/pgadmin/primary_entrypoint.sh deleted file mode 100644 index bcaf7046..00000000 --- a/src/pgadmin/primary_entrypoint.sh +++ /dev/null @@ -1,79 +0,0 @@ -#!/usr/bin/env sh - -set -e - -## Create /var/lib/pgadmin/pgpass -# 1st database -echo "$POSTGRES_HOST:$POSTGRES_PORT:postgres:$POSTGRES_USER:$POSTGRES_PASSWORD" | tee -a "/var/lib/pgadmin/pgpass" >/dev/null -echo "$POSTGRES_HOST:$POSTGRES_PORT:$POSTGRES_DB:$POSTGRES_USER:$POSTGRES_PASSWORD" | tee -a "/var/lib/pgadmin/pgpass" >/dev/null -POSTGRES_HOST_1=$POSTGRES_HOST -POSTGRES_PORT_1=$POSTGRES_PORT -POSTGRES_DB_1=$POSTGRES_DB -POSTGRES_USER_1=$POSTGRES_USER -POSTGRES_PASSWORD_1=$POSTGRES_PASSWORD - -## Create servers.json -tee /pgadmin4/servers.json >/dev/null </dev/null - echo "$POSTGRES_HOST:$POSTGRES_PORT:$POSTGRES_DB:$POSTGRES_USER:$POSTGRES_PASSWORD" | tee -a "/var/lib/pgadmin/pgpass_$COUNT" >/dev/null - - tee -a /pgadmin4/servers.json >/dev/null </dev/null <