[GH-ISSUE #106] PostgreSQL DB name not recognized #60

Closed
opened 2026-02-26 09:35:50 +03:00 by kerem · 3 comments
Owner

Originally created by @temparus on GitHub (May 17, 2018).
Original GitHub issue: https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/106

I've configured the docker container (image onlyoffice/documentserver:latest) using the following environment variables for using an external PostgreSQL database server:

POSTGRESQL_SERVER_HOST=<some-database-host>
POSTGRESQL_SERVER_PORT=5432
POSTGRESQL_SERVER_DB_NAME=<db-name>
POSTGRESQL_SERVER_USER=<correct-user>

Unfortunately, I get an error:

psql: FATAL:  no pg_hba.conf entry for host "xxx.xxx.xxx.xxx", user "<correct-user>", database "postgres", SSL off

It looks like the POSTGRESQL_SERVER_DB_NAME does not get recognized at all. Interestingly the USER variable is correctly used.
On a previous build of the image, this worked like a charm.

Were there any changes which are not reflected correctly by the README?

Originally created by @temparus on GitHub (May 17, 2018). Original GitHub issue: https://github.com/ONLYOFFICE/Docker-DocumentServer/issues/106 I've configured the docker container (image `onlyoffice/documentserver:latest`) using the following environment variables for using an external PostgreSQL database server: ``` POSTGRESQL_SERVER_HOST=<some-database-host> POSTGRESQL_SERVER_PORT=5432 POSTGRESQL_SERVER_DB_NAME=<db-name> POSTGRESQL_SERVER_USER=<correct-user> ``` Unfortunately, I get an error: ``` psql: FATAL: no pg_hba.conf entry for host "xxx.xxx.xxx.xxx", user "<correct-user>", database "postgres", SSL off ``` It looks like the `POSTGRESQL_SERVER_DB_NAME` does not get recognized at all. Interestingly the USER variable is correctly used. On a previous build of the image, this worked like a charm. Were there any changes which are not reflected correctly by the README?
kerem closed this issue 2026-02-26 09:35:50 +03:00
Author
Owner

@agolybev commented on GitHub (May 18, 2018):

Hi @temparus, What about POSTGRESQL_SERVER_PASS param? And ensure is the db and db user exist. The ones should be created before documentserver is started.

<!-- gh-comment-id:390130344 --> @agolybev commented on GitHub (May 18, 2018): Hi @temparus, What about ` POSTGRESQL_SERVER_PASS` param? And ensure is the db and db user exist. The ones should be created before documentserver is started.
Author
Owner

@temparus commented on GitHub (May 18, 2018):

Ah sure, I also use POSTGRESQL_SERVER_PASS to specify the password. The server runs on another server and has been started long before OnlyOffice. The database and the user exist.

Do I see the database postgres because that is the last possibility the pgsql client tries out?
This is weird as the server is accessible using psql with the given data.

<!-- gh-comment-id:390137347 --> @temparus commented on GitHub (May 18, 2018): Ah sure, I also use `POSTGRESQL_SERVER_PASS` to specify the password. The server runs on another server and has been started long before OnlyOffice. The database and the user exist. Do I see the database `postgres` because that is the last possibility the pgsql client tries out? This is weird as the server is accessible using `psql` with the given data.
Author
Owner

@temparus commented on GitHub (May 22, 2018):

Hm, it seems that this was not the problem. Now it works somehow but the error is still logged. I have no idea why this is. Nevermind, the problem seems to be solved.

<!-- gh-comment-id:391088979 --> @temparus commented on GitHub (May 22, 2018): Hm, it seems that this was not the problem. Now it works somehow but the error is still logged. I have no idea why this is. Nevermind, the problem seems to be solved.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Docker-DocumentServer-ONLYOFFICE#60
No description provided.