TRY 0004
This commit is contained in:
parent
0f6aeb4c5e
commit
a17db3a262
|
@ -20,14 +20,14 @@ resources:
|
|||
# - username=hydra
|
||||
# - password=NotSoSecret
|
||||
|
||||
vars:
|
||||
- name: HYDRA_DATABASE_SERVICE_NAME
|
||||
objref:
|
||||
name: hydra-postgres
|
||||
kind: Cluster
|
||||
apiVersion: postgresql.cnpg.io/v1
|
||||
fieldref:
|
||||
fieldpath: metadata.name
|
||||
#vars:
|
||||
#- name: HYDRA_DATABASE_SERVICE_NAME
|
||||
# objref:
|
||||
# name: hydra-postgres
|
||||
# kind: Cluster
|
||||
# apiVersion: postgresql.cnpg.io/v1
|
||||
# fieldref:
|
||||
# fieldpath: metadata.name
|
||||
|
||||
patches:
|
||||
- target:
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
name: HYDRA_DATABASE_USER
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: hydra-postgres-user
|
||||
name: hydra-postgres-app
|
||||
key: username
|
||||
- op: add
|
||||
path: "/spec/template/spec/containers/0/env/-"
|
||||
|
@ -12,10 +12,18 @@
|
|||
name: HYDRA_DATABASE_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: hydra-postgres-user
|
||||
name: hydra-postgres-app
|
||||
key: password
|
||||
- op: add
|
||||
path: "/spec/template/spec/containers/0/env/-"
|
||||
value:
|
||||
name: HYDRA_DATABASE_SERVICE_NAME
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: hydra-postgres-app
|
||||
key: host
|
||||
- op: add
|
||||
path: "/spec/template/spec/containers/0/env/-"
|
||||
value:
|
||||
name: DSN
|
||||
value: "postgres://$(HYDRA_DATABASE_USER):$(HYDRA_DATABASE_PASSWORD)@$(HYDRA_DATABASE_SERVICE_NAME)-rw:5432/hydra?sslmode=disable"
|
||||
value: "postgres://$(HYDRA_DATABASE_USER):$(HYDRA_DATABASE_PASSWORD)@$(HYDRA_DATABASE_SERVICE_NAME)-rw:5432/hydra?sslmode=disable"
|
||||
|
|
Loading…
Reference in New Issue