-
Notifications
You must be signed in to change notification settings - Fork 158
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
Can't use Postgres Unix Sockets with Wallabag Docker container... #174
Comments
Have you mounted the socket to the correct container? |
I can not also connect to host's PostgreSQL socket. Maybe My version: "3.8"
services:
app:
image: wallabag/wallabag
ports:
- "8081:80"
environment:
POSTGRES_PASSWORD: wallabag
POSTGRES_USER: wallabag
SYMFONY__ENV__DATABASE_DRIVER: pdo_pgsql
SYMFONY__ENV__DATABASE_DRIVER_CLASS: Wallabag\CoreBundle\Doctrine\DBAL\Driver\CustomPostgreSQLDriver
SYMFONY__ENV__DATABASE_SOCKET: /var/run/.s.PGSQL.5432
SYMFONY__ENV__DATABASE_NAME: wallabag
SYMFONY__ENV__DATABASE_USER: wallabag
SYMFONY__ENV__DATABASE_PASSWORD: wallabag
volumes:
- type: bind
source: /var/run/postgresql/.s.PGSQL.5432
target: /var/run/.s.PGSQL.5432 |
I also can not get the docker container to respect the
Here is my docker-compose file:
I have confirmed that this method of exposing the socket to an Ubuntu container running the psql command does work. Hope this helps! |
@kevinschachtschneider your setup fails because Ansible can't chown Try mounting it somewhere else, where it has permissions to chown. A bind mount might work for you: #256 might fix this. |
Trying to setup wallabag with postgres database, using unix sockets instead of TCP. Seems like adding this to ansible's entry point should work:
database_socket: "{{ lookup('env', 'SYMFONYENVDATABASE_SOCKET')|default('~', true) }}"
but unfortunately it isn't.
I have a patch, but it didn't work (so no use in a PR)
Any insights in how to make this work?
The text was updated successfully, but these errors were encountered: