Skip to content

Commit

Permalink
Enable replication for PostgreSQL (#1419)
Browse files Browse the repository at this point in the history
  • Loading branch information
Andres Martinez Gotor committed Jan 9, 2020
1 parent 35e1f70 commit 9fad582
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion chart/kubeapps/templates/assetsvc-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ spec:
- --database-type=postgresql
- --database-user=postgres
- --database-name=assets
- --database-url={{ template "kubeapps.postgresql.fullname" . }}:5432
- --database-url={{ template "kubeapps.postgresql.fullname" . }}-headless:5432
env:
- name: DB_PASSWORD
valueFrom:
Expand Down
1 change: 1 addition & 0 deletions chart/kubeapps/templates/db-secret-bootstrap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,6 @@ data:
{{- end }}
{{- if .Values.postgresql.enabled }}
postgresql-password: {{ randAlphaNum 10 | b64enc | quote }}
postgresql-replication-password: {{ randAlphaNum 10 | b64enc | quote }}
{{- end }}
{{- end -}}
3 changes: 3 additions & 0 deletions chart/kubeapps/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -536,6 +536,9 @@ mongodb:
postgresql:
## Whether to deploy a postgresql server to satisfy the applications database requirements.
enabled: false
## Enable replication for high availability
replication:
enabled: true
## Create a database for Kubeapps on the first run
postgresqlDatabase: assets
## Kubeapps uses PostgreSQL as a cache and persistence is not required
Expand Down

0 comments on commit 9fad582

Please sign in to comment.