Commit b30c9958 authored by Waqar Ahmed's avatar Waqar Ahmed

Use pg_isready for determining if postgres is up

parent 68044d48
...@@ -38,8 +38,8 @@ spec: ...@@ -38,8 +38,8 @@ spec:
{{- end }} {{- end }}
initContainers: initContainers:
- name: init-postgresdb - name: init-postgresdb
image: busybox:latest image: "postgres:13.1"
command: ['sh', '-c', "until nc -w 5 -vz {{ template "nextcloud.fullname" . }}-postgres 5432; do echo waiting for postgres; sleep 2; done"] command: ['sh', '-c', "until pg_isready -h {{ template "nextcloud.fullname" . }}-postgres; do echo waiting for postgres; sleep 2; done"]
imagePullPolicy: {{ .Values.image.pullPolicy }} imagePullPolicy: {{ .Values.image.pullPolicy }}
containers: containers:
- name: {{ .Chart.Name }} - name: {{ .Chart.Name }}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment