-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Any way to hash POSTGRES_PASSWORD or remove env vars no longer needed after setup? #316
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
Comments
You can pass it as a file using docker secrets (#225). You can also just supply a hashed password:
|
@yosifkit Thanks for the info. This helps a lot. |
Unfortunately, only by saving the content in a volume and recreating the
container after the initial setup without the variables (which is how we
usually recommend folks handle this particular case).
|
Thanks @tianon . Closing the issue. |
I just had the opportunity to try this (using pg10 beta 3) and while the cluster starts fine, I can no longer connect to it with the same password :( |
It sounds like you would actually need to edit the metadata of a docker image. In that case you could take an advantage of useing docker-copyedit. |
I am suspecting that
POSTGRES_PASSWORD
is required when creating the cluster the first time.But then it stays there for everyone to see via
docker inspect mycontainername
Even if I change the
postgres
user password, the originalPOSTGRES_PASSWORD
is still there...(and now it shows wrong password)If the environment variables are only needed for 1st time container setup, is there a way to remove them afterwards? If so should that be part of the script?
If that is not possible, is there a way to at least specify hash of the password ?
The text was updated successfully, but these errors were encountered: