Skip to content

Commit

Permalink
pgupgrade: add init container to delay startup of old deployment (PRO…
Browse files Browse the repository at this point in the history
…JQUAY-8092) (#984)

waits for existing postgresql pod to scale down before the old pod is up

Co-authored-by: Shubhra Deshpande <shubhrajayant+github.com>
  • Loading branch information
deshpandevlab authored and bcaton85 committed Oct 21, 2024
1 parent 45cc9df commit 776c242
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,15 @@ spec:
- name: postgres-data
persistentVolumeClaim:
claimName: clair-postgres-13
initContainers:
- name: check-postgres-scale-down
image: quay.io/sclorg/postgresql-13-c9s:latest
command:
- /bin/sh
- -c
- |
echo "Waiting for 30 seconds before starting the main container..."
sleep 30
containers:
- name: postgres
image: quay.io/sclorg/postgresql-13-c9s:latest
Expand Down

0 comments on commit 776c242

Please sign in to comment.