Update motech install script to use local hostname

This commit is contained in:
Disassembler 2018-11-04 19:50:23 +01:00
parent e4bf6effe1
commit 89a430fe5a
No known key found for this signature in database
GPG Key ID: 524BD33A0EE29499

View File

@ -26,8 +26,7 @@ rc-update -u
# Populate database and create admin account
service motech start
echo `date` '- Waiting for database to be populated. This should take about a minute.'
MOTECH_IP=$(awk '/ motech/ {print $1}' /etc/hosts)
until curl -s "http://${MOTECH_IP}:8080/module/server/startup/" | grep -q adminLogin; do
until curl -s "http://motech:8080/module/server/startup/" | grep -q adminLogin; do
sleep 1
done
export MOTECH_ADMIN_USER="admin"