Re: [Qgis-user] Qgis-server bullseye (stable) and sid (unstable) give blank (white) page on GetMap for all test sites

2023-05-08 Thread Mats Bjerin via QGIS-User
I finally found the solution:
For any map, to get a visual image, the type of image must be specified in the 
URL to the server with e.g. FORMAT=image/jpeg
For the osm.qgs example map from the documentation, I must specify LAYERS=OSM 
for any data to be returned.
For the world.qgs project, only the FORMAT=image/jpeg was required to make it 
work as the LAYERS=countries is already part of the suggested URL and thus 
tested by me initially.

Example of a valid URL for the osm.qgs project:
http://localhost:8080/qgis-server/?SERVICE=WMS&VERSION=1.3.0&SRS=EPSG:4326&REQUEST=GetMap&MAP=/projects/osm.qgs&BBOX=-90,-180,90,180&WIDTH=1000&HEIGHT=1000&LAYERS=OSM&FORMAT=image/png

Hope someone is helped by this.
/Mats

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] Qgis-server bullseye (stable) and sid (unstable) give blank (white) page on GetMap for all test sites

2023-05-07 Thread Mats Bjerin via QGIS-User
Hi,

I am trying to use a docker image of qgis-server as defined in the official 
documentation chapter “8. Containerized deployment”.
https://lists.osgeo.org/mailman/options/qgis-user

I have added the required nginx server and I can run the GetCapabilities test 
successfully:
http://localhost:8080/qgis-server/?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetCapabilities

I then get a complete xml spec of the server capabilities and some basic info 
on the default map (osm.qgs).

http://www.w3.org/2001/XMLSchema-instance 
xmlns:qgs=http://www.qgis.org/wms xmlns:sld=http://www.opengis.net/sld 
xmlns=http://www.opengis.net/wms xsi:schemaLocation=http://www.opengis.net/wms 
http://schemas.opengis.net/wms/1.3.0/capabilities_1_3_0.xsd 
http://www.opengis.net/sld 
http://schemas.opengis.net/sld/1.1.0/sld_capabilities.xsd 
http://www.qgis.org/wms 
http://localhost:8080/qgis-server/?SERVICE=WMS&REQUEST=GetSchemaExtension
 version="1.3.0">

WMS
Untitled

infoMapAccessService

http://www.w3.org/1999/xlink 
xlink:href=http://localhost:8080/qgis-server/ xlink:type="simple"/>
conditions unknown
None

… and so on …

I have added the file osm.qgs and also the test sample world.qgs and its 
associated SQLite database from 
(https://github.com/qgis/QGIS-Training-Data/tree/master/exercise_data/qgis-server-tutorial-data)
 to the external folder ~/data that is mounted as /data inside the container.

If I enter the running container, I can see the files owned by the qgis user in 
the /data folder.

If I try the osm.qgs map in my Chrome Browser with this call:
http://localhost:8080/qgis-server/?MAP=/data/osm.qgs&SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&CRS=EPSG:3857&WIDTH=400&HEIGHT=200&BBOX=-90,-180,90,180,
I get a blank page in return on the web page.
I had expected the Open Street Map base map to show up as a result of the call.

If I try the world.qgs map in my Chrome Browser, with the suggested call:
http://localhost:8080/qgis-server/?MAP=/data/world.qgs&LAYERS=countries&SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&CRS=EPSG:4326&WIDTH=400&HEIGHT=200&BBOX=-90,-180,90,180
I get the reply that the layer “countries” does not exist.
I had expected the simple demo map in return on the web page.

Has anyone managed to make this run?
What might I be missing?

Many thanks in advance for your advice!

Best,
/Mats B.

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user