turn off autovacuum; fix psql errors

This commit is contained in:
Grzegorz Adam Kowalski 2019-03-16 23:35:15 +01:00
parent ca32b809ea
commit 662ce85cb8

5
run.sh
View File

@ -12,11 +12,8 @@ fi
if [ "$1" = "import" ]; then if [ "$1" = "import" ]; then
# Initialize PostgreSQL # Initialize PostgreSQL
sudo -u postgres echo "autovacuum = off" >> /etc/postgresql/10/main/postgresql.custom.conf
service postgresql start service postgresql start
sudo -u postgres createuser renderer
sudo -u postgres createdb -E UTF8 -O renderer gis
sudo -u postgres psql -d gis -c "CREATE EXTENSION postgis;"
sudo -u postgres psql -d gis -c "CREATE EXTENSION hstore;"
sudo -u postgres psql -d gis -c "ALTER TABLE geometry_columns OWNER TO renderer;" sudo -u postgres psql -d gis -c "ALTER TABLE geometry_columns OWNER TO renderer;"
sudo -u postgres psql -d gis -c "ALTER TABLE spatial_ref_sys OWNER TO renderer;" sudo -u postgres psql -d gis -c "ALTER TABLE spatial_ref_sys OWNER TO renderer;"