Install cdb_geocoder extension with non-admin user

This commit is contained in:
Luis Bosque 2016-02-19 11:18:03 +01:00 committed by Mario de Frutos
parent ab32065e1d
commit 472d8c2360

View File

@ -1,7 +1,8 @@
#!/bin/bash
TARGET_DB=$1
PGUSER=${2:-postgres}
ADMIN_PGUSER="postgres"
PGUSER=${2:-${ADMIN_PGUSER}}
PYTHON_LIBRARY_NAME='cartodb_services'
function usage {
@ -32,4 +33,4 @@ CDB_DATASERVICES_SERVER_CREATE="${CREATE_EXTENSION_COMMAND} cdb_dataservices_ser
echo "* Creating extension cdb_geocoder"
psql -U ${PGUSER} -d ${TARGET_DB} -c "${CDB_GEOCODER_EXTENSION_CREATE}"
echo "* Creating extension cdb_dataservices_server"
psql -U ${PGUSER} -d ${TARGET_DB} -c "${CDB_DATASERVICES_SERVER_CREATE}"
psql -U ${ADMIN_PGUSER} -d ${TARGET_DB} -c "${CDB_DATASERVICES_SERVER_CREATE}"