diff --git a/scripts/setup/postgres-init-db b/scripts/setup/postgres-init-db index 70bece6e8f..225e25c50b 100755 --- a/scripts/setup/postgres-init-db +++ b/scripts/setup/postgres-init-db @@ -1,5 +1,10 @@ #!/bin/bash set -e + +if [ "$EUID" -ne 0 ]; then + echo "Error: This script must be run as root" >&2 + exit 1 +fi set -x # What user should we use for connecting to the database