[Dovecot] problem with postgreSQL connect=
octane indice
octane at alinto.com
Thu Sep 22 14:46:15 EEST 2005
Hello
I'm using dovecot with virtual accounts stored in a
postgreSQL db.
I use in the dovecot.conf:
auth_userdb = pgsql /usr/local/etc/dovecot-pgsql-user.conf
(and same for pass).
In the file dovecot-pgsql-user.conf, I use:
connect = host=127.0.0.1 dbname=vmail user=lecteur password=lire
user_query = SELECT '/var/spool/vhosts/'||nom_domaine||'/'||nom_boite AS
mail,5000 AS uid, 5000 AS gid FROM boites WHERE email = '%u'
It doesn't work.
If I write:
connect = dbname=vmail user=lecteur
user_query = SELECT '/var/spool/vhosts/'||nom_domaine||'/'||nom_boite AS
mail,5000 AS uid, 5000 AS gid FROM boites WHERE email = '%u'
It works.
Of course the query with psql works:
psql -U lecteur -h 127.0.0.1 vmail
-c "SELECT '/var/spool/vhosts/'||nom_domaine||'/'||nom_boite AS mail,5000 AS
uid, 5000 AS gid FROM boites WHERE email = '%u' "
with the password 'lire'
My question: do I make something wrong? I want to use the network, because
in future, dovecot will not be on the same host than postgreSQL.
Thanks
---------------------------------------------
Etes vous un consom'Acteur ? Toutes les saveurs équitables sont sur http://www.epicerie-equitable.com
More information about the dovecot
mailing list