ashwinR commited on
Commit
5ce62ba
·
1 Parent(s): a799081

Create start.sh

Browse files
Files changed (1) hide show
  1. start.sh +13 -0
start.sh ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/bin/bash
2
+ # Wait for PostgreSQL
3
+ while ! pg_isready -q -h localhost -p 5432 -U postadmin
4
+ do
5
+ echo "$(date) - waiting for database to start"
6
+ sleep 2
7
+ done
8
+
9
+ # Run migrations
10
+ alembic upgrade head
11
+
12
+ # Start Supervisor
13
+ /usr/bin/supervisord