Skip to content

Commit

Permalink
Merge pull request #59 from hamzaimran08/FIX/Studio_waits_for_db
Browse files Browse the repository at this point in the history
fix: studio waits for studio db to accept connections
  • Loading branch information
stefanhellander authored Jan 18, 2021
2 parents 29171b3 + 2fea0c8 commit 3855402
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scaleout/stackn/templates/studio-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ spec:
spec:
initContainers:
- name: wait-for-db
image: busybox:1.28
command: ['sh', '-c', "sleep 20;until nslookup {{ .Release.Name }}-studio-db.$(cat /var/run/secrets/kubernetes.io/serviceaccount/namespace).svc.cluster.local; do echo waiting for studio-db; sleep 3; done && sleep 3"]
image: postgres
command: ['sh', '-c', 'until pg_isready --host={{ .Release.Name }}-studio-db.$(cat /var/run/secrets/kubernetes.io/serviceaccount/namespace).svc.cluster.local --port=5432; do echo waiting for database; sleep 2; done;']
resources:
limits:
cpu: 100m
Expand Down

0 comments on commit 3855402

Please sign in to comment.