From e4b37fe4ca219a4614ac2b84393372e28f4c3a0b Mon Sep 17 00:00:00 2001 From: Alex Lebens Date: Fri, 3 Oct 2025 15:46:03 -0500 Subject: [PATCH] add copy --- clusters/cl01tl/management/komodo/values.yaml | 90 +++++++++++-------- 1 file changed, 51 insertions(+), 39 deletions(-) diff --git a/clusters/cl01tl/management/komodo/values.yaml b/clusters/cl01tl/management/komodo/values.yaml index 1cd885de6..6143c51c4 100644 --- a/clusters/cl01tl/management/komodo/values.yaml +++ b/clusters/cl01tl/management/komodo/values.yaml @@ -101,49 +101,13 @@ komodo: requests: cpu: 10m memory: 128Mi - # copy: - # image: - # repository: ghcr.io/moghtech/komodo-cli - # tag: latest - # pullPolicy: IfNotPresent - # command: ["km"] - # args: ["database", "copy", "-y"] - # env: - # - name: DB_USERNAME - # valueFrom: - # secretKeyRef: - # name: komodo-postgresql-17-cluster-app - # key: user - # - name: DB_PASSWORD - # valueFrom: - # secretKeyRef: - # name: komodo-postgresql-17-cluster-app - # key: password - # - name: KOMODO_DATABASE_URI - # value: mongodb://$(DB_USERNAME):$(DB_PASSWORD)@localhost:27017/komodo?authMechanism=PLAIN - # - name: KOMODO_DATABASE_DB_NAME - # value: komodo - # - name: TARGETDB_PASSWORD - # valueFrom: - # secretKeyRef: - # name: komodo-postgresql-17-fdb-cluster-superuser - # key: password - # - name: TARGETDB_HOST - # valueFrom: - # secretKeyRef: - # name: komodo-postgresql-17-fdb-cluster-superuser - # key: host - # - name: KOMODO_CLI_DATABASE_TARGET_URI - # value: mongodb://postgres:${TARGETDB_PASSWORD}@migrate:27017 - # - name: KOMODO_CLI_DATABASE_TARGET_DB_NAME - # value: komodo - migrate: + ferretdb: type: deployment replicas: 1 strategy: Recreate revisionHistoryLimit: 3 containers: - ferretdb2: + main: image: repository: ghcr.io/ferretdb/ferretdb tag: 2.5.0 @@ -165,6 +129,48 @@ komodo: requests: cpu: 10m memory: 128Mi + copy: + type: deployment + replicas: 1 + strategy: Recreate + revisionHistoryLimit: 3 + containers: + main: + image: + repository: ghcr.io/moghtech/komodo-cli + tag: latest + pullPolicy: IfNotPresent + command: ["km"] + args: ["database", "copy", "-y"] + env: + - name: DB_USERNAME + valueFrom: + secretKeyRef: + name: komodo-postgresql-17-cluster-app + key: user + - name: DB_PASSWORD + valueFrom: + secretKeyRef: + name: komodo-postgresql-17-cluster-app + key: password + - name: KOMODO_DATABASE_URI + value: mongodb://$(DB_USERNAME):$(DB_PASSWORD)@komodo.komodo:27017/komodo?authMechanism=PLAIN + - name: KOMODO_DATABASE_DB_NAME + value: komodo + - name: TARGETDB_PASSWORD + valueFrom: + secretKeyRef: + name: komodo-postgresql-17-fdb-cluster-superuser + key: password + - name: TARGETDB_HOST + valueFrom: + secretKeyRef: + name: komodo-postgresql-17-fdb-cluster-superuser + key: host + - name: KOMODO_CLI_DATABASE_TARGET_URI + value: mongodb://postgres:${TARGETDB_PASSWORD}@ferretdb.komodo:27017 + - name: KOMODO_CLI_DATABASE_TARGET_DB_NAME + value: komodo service: main: controller: main @@ -173,7 +179,13 @@ komodo: port: 80 targetPort: 9120 protocol: HTTP - + ferretdb: + controller: ferretdb + ports: + http: + port: 27017 + targetPort: 27017 + protocol: HTTP persistence: cache: storageClass: ceph-block