New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creation multiple users and databases #240

Closed
wants to merge 7 commits into
base: master
from

Conversation

Projects
None yet
3 participants
@xtimon
Copy link

xtimon commented Dec 20, 2016

Execute for test:
docker run --name some-postgres -p 5432:5432 -e POSTGRES_USERS="user1:user1pass|user2:user2pass|user3:user3password" -e POSTGRES_DATABASES="database1:user1|database2:user2|database3:user3" -e POSTGRES_CONFIGS="work_mem:15MB|fsync:off|full_page_writes:off" -d xtimon/postgres

xtimon added some commits Dec 20, 2016

fix
@gmile

This comment has been minimized.

Copy link

gmile commented Jul 7, 2017

Is there anything to be done before this is merged? In case there's a reason this is not going to be merged – what is the official / proper way for adding new users / databases?

@yosifkit

This comment has been minimized.

Copy link
Member

yosifkit commented Jul 10, 2017

Related issues: docker-library/mysql#213, docker-library/mysql#86, docker-library/mysql#18, docker-library/mariadb#63.

So, the answer is to just put scripts in /docker-entrypoint-initdb.d/:

@yosifkit yosifkit closed this Jul 10, 2017

@xtimon

This comment has been minimized.

Copy link

xtimon commented Jul 10, 2017

The official way for adding new users / databases is the same. I didn't broke it. All the environments POSTGRES_PASSWORD, POSTGRES_USER, POSTGRES_DB work as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment