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

Postgres env #15

Open
sebastienbeau opened this issue Dec 2, 2022 · 2 comments
Open

Postgres env #15

sebastienbeau opened this issue Dec 2, 2022 · 2 comments

Comments

@sebastienbeau
Copy link

sebastienbeau commented Dec 2, 2022

Hi Stéphane

I see that you face the same issue as me ;) :
bcc6246

I think the best option is to pass to the container the postgres variable directly in the confd, so when you enter in the container psql work

PGHOST
PGPORT
PGUSER
PGPASSWORD
PGDATABASE

And simply removing the variable
DB_HOST
DB_PORT
DB_USER
DB_PASSWORD
DB_NAME

So we always have the postgres variable set.

In our case we have done this hack in our image (based on your)

https://github.com/akretion/odoo-docker/blob/master/bin/ak-entrypoint.sh#L10

I will be happy to remove this hack if we can directly use postgres var in confd

@sebastienbeau
Copy link
Author

@sbidoul

@sbidoul
Copy link
Member

sbidoul commented Dec 2, 2022

Yes that would be nice.

Concerns are backward compatibility and the fact that DB_NAME may contain a comma-separated list of database names.

I had other priorities, so for we set both DB_* and PG* environment variables in the deployments.

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