kopia lustrzana https://github.com/kartoza/docker-postgis
commit
5e586a414e
|
@ -53,11 +53,11 @@ else
|
||||||
VOLUME_OPTION=""
|
VOLUME_OPTION=""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -d $HOST_DATA_DIR ]
|
if [ ! -d $VOLUME ]
|
||||||
then
|
then
|
||||||
mkdir $HOST_DATA_DIR
|
mkdir $VOLUME
|
||||||
fi
|
fi
|
||||||
chmod a+w $HOST_DATA_DIR
|
chmod a+w $VOLUME
|
||||||
|
|
||||||
docker kill ${CONTAINER_NAME}
|
docker kill ${CONTAINER_NAME}
|
||||||
docker rm ${CONTAINER_NAME}
|
docker rm ${CONTAINER_NAME}
|
||||||
|
|
|
@ -96,7 +96,7 @@ else
|
||||||
su - postgres -c "psql template_postgis -c 'GRANT ALL ON spatial_ref_sys TO PUBLIC;'"
|
su - postgres -c "psql template_postgis -c 'GRANT ALL ON spatial_ref_sys TO PUBLIC;'"
|
||||||
# Create a default db called 'gis' that you can use to get up and running quickly
|
# Create a default db called 'gis' that you can use to get up and running quickly
|
||||||
# It will be owned by the docker db user
|
# It will be owned by the docker db user
|
||||||
su - postgres -c "createdb -O docker -T template_postgis gis"
|
su - postgres -c "createdb -O $USERNAME -T template_postgis gis"
|
||||||
fi
|
fi
|
||||||
# This should show up in docker logs afterwards
|
# This should show up in docker logs afterwards
|
||||||
su - postgres -c "psql -l"
|
su - postgres -c "psql -l"
|
||||||
|
|
Ładowanie…
Reference in New Issue