Browse Source

update postgresql init db example file (#1689)

ahkui 6 years ago
parent
commit
85c57a0b6f
1 changed files with 3 additions and 4 deletions
  1. 3 4
      postgres/docker-entrypoint-initdb.d/createdb.sh.example

+ 3 - 4
postgres/docker-entrypoint-initdb.d/createdb.sh.example

@@ -13,20 +13,19 @@
 #
 # this sh script will auto run when the postgres container starts and the $DATA_PATH_HOST/postgres not found.
 #
-
-set -e
+# 
 # psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
 #     CREATE USER db1 WITH PASSWORD 'db1';
 #     CREATE DATABASE db1;
 #     GRANT ALL PRIVILEGES ON DATABASE db1 TO db1;
 # EOSQL
-
+# 
 # psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
 #     CREATE USER db2 WITH PASSWORD 'db2';
 #     CREATE DATABASE db2;
 #     GRANT ALL PRIVILEGES ON DATABASE db2 TO db2;
 # EOSQL
-
+# 
 # psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
 #     CREATE USER db3 WITH PASSWORD 'db3';
 #     CREATE DATABASE db3;