#!/bin/sh set -e until nc -z "$POSTGRES_HOST" "$POSTGRES_PORT"; do echo "Waiting for postgres at $POSTGRES_HOST:$POSTGRES_PORT..." sleep 1 done celery -A config worker -l info