[Qgis-developer] qgis-web-client: module wsgi

Enzo Cocca enzo.ccc at gmail.com
Wed Apr 22 01:12:06 PDT 2015


Thanks Bernard

You are right, but now It not found the path wsgi folder

"The requested URL /wsgi/search.wsgi was not found on this server."

in globalOptions. js I set :

//URL for custom search scriptsnull; //
var searchBoxQueryURL =  "/wsgi/search.wsgi?query="; // null:
var searchBoxGetGeomURL =  "/wsgi/getSearchGeom.wsgi";//null; //
 and

in /etc/apache2/sites-available/default
I set
#mod_wsgi
  WSGIDaemonProcess gis processes=5 threads=15 display-name=%{GROUP}
  WSGIScriptAlias /wsgi/ /home/www/wsgi/
  WSGIScriptAliasMatch ^/wsgi/([^/]+) /home/www/wsgi/$1.wsgi

and than I restarted apache

Where I wrong?


2015-04-22 11:26 GMT+04:00 Bernhard Ströbl <bernhard.stroebl at jena.de>:

> Hi Enzo,
>
> your error indicates that the script is not executed as a server script
> but instead delivered to the client. Thjis should not happen, as it is a
> high security risk (db internals are exposed).
>
> Have you enabled mod_wsgi on your apache server as described in section
> 6.2.1 of the QWC documentation?
>
> You also should follow this line (section 6 the documentation): "It is
> recommended to install the wsgi scripts in a separate directory, e.g.
> /home/www/wsgi, a place that is not reachable by regular web traffic."
>
> Bernhard
>
> Am 22.04.2015 09:15, schrieb Enzo Cocca:
>
>> Tahnks Bernhard,
>>
>> I know, I have followed the procedure from official guideline
>> https://github.com/qgis/QGIS-Web-Client
>>
>> but when execute a sample query in Firefox, like written in the
>> search.wsgi file, Firefox only visualize the file search.wsgi like a
>> text file.
>>
>> and I have the error
>> "illegal character
>>    #!/usr/bin/python"
>>
>> So I not understand the problem....
>>
>> Thanks!!
>>
>>
>>
>> 2015-04-22 10:51 GMT+04:00 Bernhard Ströbl <bernhard.stroebl at jena.de
>> <mailto:bernhard.stroebl at jena.de>>:
>>
>>     Hi,
>>
>>     the wsgi-Script is a script to be run _on the server_, not in the
>>     client.
>>
>>     Bernhard
>>
>>     Am 22.04.2015 08:47, schrieb Enzo Cocca:
>>
>>         Hi,
>>         I have one questionç
>>
>>         I try to write a searchtext in the client, Firebug gives the error
>>         message:
>>
>>         "illegal character
>>            #!/usr/bin/python"
>>
>>         Someone have a idea??
>>
>>         thanks!!
>>
>>
>>
>>     __________ Information from ESET Mail Security, version of virus
>>     signature database 11513 (20150422) __________
>>
>>     The message was checked by ESET Mail Security.
>>     http://www.eset.com
>>
>>
>>     _______________________________________________
>>     Qgis-developer mailing list
>>     Qgis-developer at lists.osgeo.org <mailto:Qgis-developer at lists.osgeo.org
>> >
>>     http://lists.osgeo.org/mailman/listinfo/qgis-developer
>>
>>
>>
>>
>>
>
> __________ Information from ESET Mail Security, version of virus signature
> database 11513 (20150422) __________
>
> The message was checked by ESET Mail Security.
> http://www.eset.com
>
>
>


-- 
Enzo Cocca PhD
in "Science and Technology for Archaeology and Cultural Heritage"
mail: enzo.ccc at gmail.com
cell: +393495087014
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20150422/d719e85e/attachment-0001.html>


More information about the Qgis-developer mailing list