gws.server
¶
Configuration and management of embedded servers.
GWS runs several servers in the container: WSGI backend servers (Web and Mapproxy), the Spool server for background jobs and the frontend NGINX proxy.
This module provides configuration and control utilities for these facilities. It handles GWS startups and reloads.
The GWS startup sequence is the following:
the main script
bin/gws
invokes thestart
command ingws.server.cli
CLI delegates to
gws.server.control
control invokes the
Application
configuration ingws.base.application.core.Object
the Application creates a
ServerManager
(gws.server.manager.Object
)the Manager creates configuration files for embedded servers and a startup shell script to start them
the control is returned to
bin/gws
, which invokes the startup scriptthe script starts the backends and finally NGINX, which keeps running in foreground
Source code: gws.server
Subpackages¶
Submodules¶
Package Contents¶
- class gws.server.Config(*args, **kwargs)¶
Bases:
gws.Config
Server module configuration
- autoRun: str = ''¶
Shell command to run before the server start. (deprecated in 8.2)
- mapproxy: MapproxyConfig | None¶
Bundled Mapproxy module.
- monitor: MonitorConfig | None¶
Monitor configuration.
- postConfigure: str = ''¶
Shell or python script to run run after the service has been configured. (added in 8.2)
- preConfigure: str = ''¶
Shell or python script to run before configuring the server. (added in 8.2)
- qgis: QgisConfig | None¶
Qgis server configuration.
- spool: SpoolConfig | None¶
Spool server module.
- templates: list[gws.ext.config.template] | None¶
Configuration templates.
- timeout: gws.Duration = '60'¶
Server timeout. (deprecated in 8.1)
- timeZone: str = 'Europe/Berlin'¶
Timezone for this server.
- withMapproxy: bool = True¶
Enable the mapproxy server. (added in 8.2)
- withMonitor: bool = True¶
Enable the monitor. (added in 8.2)
- withSpool: bool = True¶
Enable the spool server. (added in 8.2)
- withWeb: bool = True¶
Enable the web server. (added in 8.2)