[Qgis-user] QGIS server and pg_service.conf

Alessandro Pasotti apasotti at gmail.com
Mon Sep 10 00:23:33 PDT 2018


Hi,

sorry for the delay: I missed the thread


the QGIS auth system was designed to work with the server, this comment in
the code explains how to configure it, I'm not sure if this is documented
somewhere else, if not, we should add a paragraph in the docs:


  //   Initialize the authentication system

  //   creates or uses qgis-auth.db in ~/.qgis3/ or directory defined
by QGIS_AUTH_DB_DIR_PATH env variable

  //   set the master password as first line of file defined by
QGIS_AUTH_PASSWORD_FILE env variable

  //   (QGIS_AUTH_PASSWORD_FILE variable removed from environment
after accessing)



Hope this helps.



On Thu, Sep 6, 2018 at 8:34 PM Andreas Neumann <a.neumann at carto.net> wrote:

> Hi Thomas,
>
> Does it work now?
>
> It might also be a different issue. It might be an authentication issue.
> If you used authentication manager and don't store the login and password
> in the QGIS project file, there may be issues. In that case you also have
> to do something (I don't know exactly what) to enable authentication
> manager on QGIS server to read the credentials. I also wonder how to handle
> such cases. For that reason, I still store the login name and password in
> the qgs project files, instead of using the authentication manager.
>
> If this is the case, maybe Alessandro can help?
>
> Greetings,
>
> Andreas
>
> Am 06.09.2018 um 15:32 schrieb Etienne Trimaille:
>
> Either use PGSERVICEFILE or put it /etc/postgresql-common/pg_service.conf.
> It's working well for me with QGIS 2.18.23.
>
> Le jeu. 6 sept. 2018 à 07:55, Jürgen E. Fischer <jef at norbit.de> a écrit :
>
>> Hi Thomas,
>>
>> On Thu, 06. Sep 2018 at 13:44:40 +0200, Thomas Schüttenberg wrote:
>> > Yes, I did that. The environment variable PGSYSCONFDIR is set also on
>> the
>> > server machine, it points to the same connection file and it works:
>> QGIS on
>> > the server pc can load layers with this service parameter.
>>
>> PGSERVICEFILE?
>>
>>
>> Jürgen
>>
>> --
>> Jürgen E. Fischer           norBIT GmbH             Tel.
>> +49-4931-918175-31
>> Dipl.-Inf. (FH)             Rheinstraße 13          Fax.
>> +49-4931-918175-50
>> Software Engineer           D-26506 Norden
>> http://www.norbit.de
>> QGIS release manager (PSC)  Germany                    IRC: jef on
>> FreeNode
>> _______________________________________________
>> Qgis-user mailing list
>> Qgis-user at lists.osgeo.org
>> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
>> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
>
>
> _______________________________________________
> Qgis-user mailing listQgis-user at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
>
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user



-- 
Alessandro Pasotti
w3:   www.itopen.it
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20180910/5b26916b/attachment.html>


More information about the Qgis-user mailing list