Skip to content
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

Does _FILE work for REPLICATION_PASSWORD for using docker secrets #3

Open
dave08 opened this issue Jun 27, 2017 · 2 comments
Open

Does _FILE work for REPLICATION_PASSWORD for using docker secrets #3

dave08 opened this issue Jun 27, 2017 · 2 comments

Comments

@dave08
Copy link

dave08 commented Jun 27, 2017

Thanks for the great implementation! This is the best, most non-intrusive I've found after lots of googling. The main image translates any environment variable with _FILE extension to the value contained in the file. This allows for not exposing secrets on production servers. Does this image also do that?

Thanks again!

@nebirhos
Copy link
Owner

Hi @dave08, and thanks for your interest in this project!

It does't work out of the box, but I think we can import the function from https://github.com/docker-library/postgres/blob/master/9.6/docker-entrypoint.sh#L8.

I never tried the file_env feature. Why not setting the password at runtime with -e REPLICATION_PASSWORD="xxx"?

@dave08
Copy link
Author

dave08 commented Jun 28, 2017

See: https://diogomonica.com/2017/03/27/why-you-shouldnt-use-env-variables-for-secret-data/ for explanation of why, and: DanielDent/docker-postgres-replication#7 for possible how.. I just don't understand enough about replication and pg, and am very limited for time (like everybody :) ) to actually make these changes with a pull.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants