Skip to content

Instantly share code, notes, and snippets.

@typetetris
Last active Nov 6, 2020
Embed
What would you like to do?
#!/usr/bin/env bash
mkdir -p sandbox
if pg_ctl -D sandbox/db status | grep 'is running' > /dev/null
then
echo "already running"
else
pg_ctl -w -D sandbox/db -l sandbox/dblogfile start
fi
# psql -h localhost -p 5431 -U dev dev # to connect
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment