This repository will build images only up to 1.2.x versions
Setup a OGC WWS/WFS/WCS service.
Run the python qgis server from https://github.com/3liz/py-qgis-server in a docker container.
docker run -p 8080:8080 \
-v /path/to/qgis/projects:/projects \
-e QGSRV_SERVER_WORKERS=2 \
-e QGSRV_LOGGING_LEVEL=DEBUG \
-e QGSRV_CACHE_ROOTDIR=/projects \
-e QGSRV_CACHE_SIZE=10 \
3liz/qgis-map-server
The OWS requests use the following format: /ows/?<ows_query_params>
Example:
http://myserver:8080/ows/?SERVICE=WFS&VERSION=1.1.0&REQUEST=GetCapabilities
MAP arguments are treated as relative to the location given by QYWPS_CACHE_ROOTDIR
The server is configured via environment variables or configuration file as described here
By default, the server ren as user and group id 9001. The user id may be customized by setting
the QGSRV_USER
environment variable to the - numerical - user ID of your choice
The cache hold projects, if the project timestamp change on disk then the project will be reloaded.
Xvfb display support can be activate with QGSRV_DISPLAY_XVFB=ON
which is the default behavior.
Plugins can be used from a host mounted volume; use the QGSRV_SERVER_PLUGINPATH environment variables to set the path inside the container.
You may pass QGIS server environment variables by defining them as docker environment variables.
Useful variables are:
QGIS_OPTIONS_PATH # Path to look for qgis settings ini file
QGIS_SERVER_PARALLEL_RENDERING # Enable/Disable QGIS_SERVER_PARALLEL_RENDERING (default to false)
QGIS_SERVER_MAX_THREADS # Max num rendering threads (per processes) - default unlimited
QGIS_SERVER_WMS_MAX_HEIGHT # Maximum height for a WMS request - default not set
QGIS_SERVER_WMS_MAX_WIDTH # Maximum width for a WMS request - default not set
In order to use the server with lizmap, you must set the following configuration
in your lizmapConfig.ini.php
:
[services]
wmsServerURL="http://my.domain:<port>/ows/"
...
; Use relative path
relativeWMSPath=true
GeoPackages is not multiprocessing friendly and are not working well with read-only volumes: avoid them if you if you intend to use your data with read-only volumes.