Skip to content

Commit 8c92a03

Browse files
authored
Merge pull request #55 from camptocamp/backport/52-to-master
Be able to configure the timeout
2 parents caf0648 + fbc72a9 commit 8c92a03

File tree

3 files changed

+21
-20
lines changed

3 files changed

+21
-20
lines changed

Dockerfile

+6-6
Original file line numberDiff line numberDiff line change
@@ -117,12 +117,12 @@ ENV QGIS_SERVER_LOG_LEVEL=0 \
117117
MAX_CACHE_LAYERS="" \
118118
QGIS_PLUGINPATH=/var/www/plugins \
119119
QGIS_AUTH_DB_DIR_PATH=/etc/qgisserver/ \
120-
MAX_REQUESTS_PER_PROCESS=1000 \
121-
MIN_PROCESSES=1 \
122-
MAX_PROCESSES=5 \
123-
BUSY_TIMEOUT=300 \
124-
IDLE_TIMEOUT=300 \
125-
IO_TIMEOUT=40
120+
FCGID_MAX_REQUESTS_PER_PROCESS=1000 \
121+
FCGID_MIN_PROCESSES=1 \
122+
FCGID_MAX_PROCESSES=5 \
123+
FCGID_BUSY_TIMEOUT=300 \
124+
FCGID_IDLE_TIMEOUT=300 \
125+
FCGID_IO_TIMEOUT=40
126126

127127
COPY --from=builder /usr/local/bin /usr/local/bin/
128128
COPY --from=builder /usr/local/lib /usr/local/lib/

README.md

+9-8
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,16 @@ You can use the following variables (`-e` option in `docker run`):
1919
* QGIS_SERVER_LOG_LEVEL: The debug level for the logs (0=max debug, 3=no debug logs)
2020
* PGSERVICEFILE: If you want to change the default of `/etc/qgisserver/pg_service.conf`
2121
* QGIS_PROJECT_FILE: If you want to change the default of `/etc/qgisserver/project.qgs`
22-
* MAX_REQUESTS_PER_PROCESS: The number of requests a QGIS server will serve before being restarted by apache
23-
* MIN_PROCESSES: The minimum number of fcgi processes to keep (defaults to 1)
24-
* MAX_PROCESSES: The maximum number of fcgi processes to keep (defaults to 5)
2522
* QGIS_CATCH_SEGV: Set to "1" if you want stacktraces in the logs in case of segmentation faults.
26-
* BUSY_TIMEOUT: The maximum time limit for request handling (defaults to 300)
27-
* IDLE_TIMEOUT: Application processes which have not handled a request for
28-
this period of time will be terminated (defaults to 300)
29-
* IO_TIMEOUT: The maximum period of time the module will wait while trying to
30-
read from or write to a FastCGI application (defaults to 40)
23+
* FCGID_MAX_REQUESTS_PER_PROCESS: The number of requests a QGIS server will serve before being restarted by apache
24+
* FCGID_MIN_PROCESSES: The minimum number of fcgi processes to keep (defaults to 1)
25+
* FCGID_MAX_PROCESSES: The maximum number of fcgi processes to keep (defaults to 5)
26+
* FCGID_IO_TIMEOUT: This is the maximum period of time the module will wait while trying to read from or
27+
write to a FastCGI application (default to 40)
28+
* FCGID_BUSY_TIMEOUT: The maximum time limit for request handling (defaults to 300)
29+
* FCGID_IDLE_TIMEOUT: Application processes which have not handled a request for
30+
this period of time will be terminated (defaults to 300)
31+
3132
Fonts present in the `/etc/qgisserver/fonts` directory will be installed and thus usable by QGIS.
3233

3334
## Running the client

runtime/etc/apache2/conf-enabled/qgis.conf

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# QGIS has memory leaks, this limit should improve long term memory usage
2-
FcgidMaxRequestsPerProcess ${MAX_REQUESTS_PER_PROCESS}
3-
FcgidMinProcessesPerClass ${MIN_PROCESSES}
4-
FcgidMaxProcessesPerClass ${MAX_PROCESSES}
5-
FcgidBusyTimeout ${BUSY_TIMEOUT}
6-
FcgidIdleTimeout ${IDLE_TIMEOUT}
7-
FcgidIOTimeout ${IO_TIMEOUT}
2+
FcgidMaxRequestsPerProcess ${FCGID_MAX_REQUESTS_PER_PROCESS}
3+
FcgidMinProcessesPerClass ${FCGID_MIN_PROCESSES}
4+
FcgidMaxProcessesPerClass ${FCGID_MAX_PROCESSES}
5+
FcgidBusyTimeout ${FCGID_BUSY_TIMEOUT}
6+
FcgidIdleTimeout ${FCGID_IDLE_TIMEOUT}
7+
FcgidIOTimeout ${FCGID_IO_TIMEOUT}
88

99
ScriptAliasMatch "^/.*" /usr/local/bin/qgis-mapserv-wrapper
1010
<LocationMatch "^/.*">

0 commit comments

Comments
 (0)