Configuration
The plugin is set with environment variables of QGIS Server (or py-qgis-server). All of them are optional.
Variable |
Default |
Meaning |
|---|---|---|
|
|
|
|
public tiles (AWS) |
URL template of the tiles ( |
|
|
Folder of the Copernicus disk cache. |
|
|
Maximum size of the cache, in MB ( |
|
|
Maximum number of points of a profile. |
The default URL of the Copernicus tiles is
https://copernicus-dem-30m.s3.amazonaws.com/{name}/{name}.tif.
Where to set them?
py-qgis-server: in the environment of the service (
.envfile, systemd unit,docker-compose.yml…).QGIS Server as FastCGI: in the web server configuration, e.g.
fastcgi_param(nginx) orFcgidInitialEnv(Apache).
Example for a systemd unit:
[Service]
Environment=ELEVATIONPROFILE_COPERNICUS_CACHE_DIR=/var/cache/elevationprofile
Environment=ELEVATIONPROFILE_COPERNICUS_CACHE_MB=4096
Restart QGIS Server after a change.
Proxy
If QGIS Server reaches the Internet through a proxy, set GDAL_HTTP_PROXY (and if needed
GDAL_HTTP_PROXYUSERPWD): Copernicus is read by GDAL.
Logs
The messages of the plugin are written in the QGIS Server logs, under the name
Elevation Profile Server, with the X-Request-ID header of the request when it is given. Each
Copernicus read is logged with its duration and where its blocks came from, e.g.:
Copernicus: 537 points, 2 blocks (1 from the disk cache, 1 downloaded) in 1.35 s