Skip to content

Commit 5370a99

Browse files
committed
Add Debugging section to README
1 parent b77f815 commit 5370a99

File tree

1 file changed

+31
-1
lines changed

1 file changed

+31
-1
lines changed

README.md

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ for more information about QGIS Server specifc environment variables.
3636
|MAX_CACHE_LAYERS|500|QGIS Server|
3737
|QGIS_PROJECT_SUFFIX|qgs|QGIS Server|
3838
|DB_PROJECT_SERVICE|qgisprojects|QGIS Server|
39-
|QGIS_DEBUG|1 | QGIS Server|
39+
|QGIS_DEBUG|0 | QGIS Server|
4040
|QGIS_SERVER_ALLOWED_EXTRA_SQL_TOKENS|""|QGIS Server|
4141
|QGIS_SERVER_API_WFS3_MAX_LIMIT|10000|QGIS Server|
4242
|QGIS_SERVER_CACHE_SIZE|0|QGIS Server|
@@ -136,3 +136,33 @@ Log monitoring
136136
--------------
137137

138138
You can monitor the `n` last lines of the QGIS Server logs via `/logs?n=<n>`, i.e. `http://localhost:8001/logs?n=100`.
139+
140+
Debugging
141+
---------
142+
143+
The basic QGIS Server log output verbosity can be controlled via `QGIS_SERVER_LOG_LEVEL` (see https://docs.qgis.org/3.40/en/docs/server_manual/config.html). A `QGIS_SERVER_LOG_LEVEL: 0` will enable the most verbose log output. Default ist `QGIS_SERVER_LOG_LEVEL: 1`.
144+
145+
For further debugging, nightly release debug images are available, which are tagged as `<version>-nightly>`. You can enable debug output by setting `QGIS_DEBUG` to a level above 0 (the higher the level, the more verbose the log output). Sample `docker-compose.yml` configuration:
146+
147+
```yml
148+
qwc-qgis-server:
149+
image: docker.io/sourcepole/qwc-qgis-server:3.44-nightly
150+
environment:
151+
QGIS_SERVER_LOG_LEVEL: 0
152+
QGIS_DEBUG: 1
153+
...
154+
```
155+
156+
For even further debugging, you can locally build the `qwc-qgis-server` image with root access as follows:
157+
158+
```yml
159+
qwc-qgis-server:
160+
build:
161+
context: ./qwc-services/qwc-qgis-server
162+
args:
163+
QGIS_REPO: <ubuntu|ubuntu-ltr|ubuntu-nightly-release>
164+
ROOT_PASSWORD: '<password>'
165+
...
166+
```
167+
168+
and then install the debug tools of your choice inside the container (`docker compose exec qwc-qgis-server bash`).

0 commit comments

Comments
 (0)