File tree Expand file tree Collapse file tree 1 file changed +3
-19
lines changed
Expand file tree Collapse file tree 1 file changed +3
-19
lines changed Original file line number Diff line number Diff line change @@ -15,35 +15,19 @@ mechanism.
1515
1616## Usage
1717
18- ### By mounting a volume
19-
20- Clone the repository, mount its directory as a volume into
21- ` /docker-entrypoint-initdb.d ` and declare database names separated by commas in
22- ` POSTGRES_MULTIPLE_DATABASES ` environment variable as follows
23- (` docker-compose ` syntax):
24-
25- myapp-postgresql:
26- image: postgres:9.6.2
27- volumes:
28- - ../docker-postgresql-multiple-databases:/docker-entrypoint-initdb.d
29- environment:
30- - POSTGRES_MULTIPLE_DATABASES=db1,db2
31- - POSTGRES_USER=myapp
32- - POSTGRES_PASSWORD=
33-
3418### By building a custom image
3519
3620Clone the repository, build and push the image to your Docker repository,
3721for example for Google Private Repository do the following:
3822
39- docker build --tag=eu.gcr.io/your-project/postgres-multi-db .
40- gcloud docker -- push eu.gcr.io/your-project/postgres-multi-db
23+ docker build --tag=theplant/postgresmd:9 .
24+ gcloud docker -- push theplant/postgresmd:9
4125
4226You still need to pass the ` POSTGRES_MULTIPLE_DATABASES ` environment variable
4327to the container:
4428
4529 myapp-postgresql:
46- image: eu.gcr.io/your-project/postgres-multi-db
30+ image: theplant/postgresmd:9
4731 environment:
4832 - POSTGRES_MULTIPLE_DATABASES=db1,db2
4933 - POSTGRES_USER=myapp
You can’t perform that action at this time.
0 commit comments