Use Docker to deploy your application¶
Docker Images¶
When you build your application, the following images will be generated:
camptocamp/<package>_geoportal:latest
camptocamp/<package>_config:latest
The tag is by default latest
, but you can change it by setting the DOCKER_TAG
Makefile variable.
Docker compose files¶
docker-compose.yaml
: The main file that describes the composition.docker-compose-lib.yaml
: Provideis the base description of Geomapfish Docker services..env
: Generated from the env files; contains the environment variables used by the composition.docker-compose.override[.sample].yaml
: Some rules for debuggung..env
: The variable used in the compose files.
Run the developer composition¶
docker-compose up -d
You can then access your application with https://localhost:8484/.
Clean¶
Docker does not clean anything automatically, in particular it does not clean any images, therefore disk space may become problematic after a certain number of builds. You can use the following commands to manually remove Docker files.
Use docker system prune
to clean files; you can add the --all
option to do a deeper clean.
Environment variables¶
The GeoMapFish containers can be customized with some environment variables:
Config:
VISIBLE_WEB_HOST
: The web host visible by the browser e.g.: ‘example.com’.
VISIBLE_ENTRY_POINT
: The web path visible by the browser e.g.: ‘/main/’, default to ‘/’.
PGSCHEMA
: The postgres schema, used by MapServer.
GEOPORTAL_INTERNAL_URL
: Used by the print in non mutualize mode.
TILECLOUDCHAIN_INTERNAL_URL
: Used by the print in non mutualize mode.
ST_JOIN
: Can beST_Collect
(default) orST_Union
,ST_Collect
is better for performance but does not support restriction area intersection.
Geoportal:
VISIBLE_ENTRY_POINT
: The web path visible by the browser e.g.: ‘/main/’, default to ‘/’.
PGSCHEMA
: The postgres schema, used by MapServer.
AUTHTKT_TIMEOUT
: See: Authentication.
AUTHTKT_REISSUE_TIME
: See: Authentication.
AUTHTKT_MAXAGE
: See: Authentication.
AUTHTKT_SECRET
: See: Authentication.
AUTHTKT_COOKIENAME
: See: Authentication.
AUTHTKT_HTTP_ONLY
: See: Authentication.
AUTHTKT_SECURE
: See: Authentication.
AUTHTKT_SAMESITE
: See: Authentication.
BASICAUTH
: See: Authentication.
LOG_TYPE
: Should be ‘console’ with Docker Compose and ‘json’ with OpenShift.
LOG_LEVEL
: Log level for your application, default toINFO
, can beDEBUG
,INFO
,WARNING
,ERROR
,CRITICAL
orNOTSET
, see also theproduction.ini
file and the logging documentation.
C2CGEOPORTAL_LOG_LEVEL
: Log level for all c2cgeoportal modules, default toWARN
.
C2CWSGIUTILS_LOG_LEVEL
: Log level for c2cwsgiutils, default toINFO
.
GUNICORN_LOG_LEVEL
: Log level for Gunicorn, default toINFO
.
SQL_LOG_LEVEL
: Log level for the SQLAlchemy engine``, default toWARN
.
DOGPILECACHE_LOG_LEVEL
: Log level for Dogpile cache, default toINFO
.
OTHER_LOG_LEVEL
: Log level for other modules, default toWARN
.
C2CGEOPORTAL_THEME_TIMEOUT
: Timeout in seconds used in requests on OGC servers during themes generation, default to300
.
QGIS server:
GEOMAPFISH_CONFIG
: The GeoMapFish config file, default to/etc/qgisserver/geomapfish.yaml
.
GEOMAPFISH_OGCSERVER
: The OGC server name in single QGIS project mode.
GEOMAPFISH_ACCESSCONTROL_CONFIG
: The access control config file for multi QGIS project mode.
GEOMAPFISH_POSITION
: The plugin position, default to100
.
LOG_LEVEL
: Log level for the GeoMapFish plugins, see also thelogging.ini
file.
C2CGEOPORTAL_LOG_LEVEL
: Log level for all c2cgeoportal modules, default toINFO
.
C2CWSGIUTILS_LOG_LEVEL
: Log level for c2cwsgiutils, default toINFO
.
SQL_LOG_LEVEL
: Log level for the SQLAlchemy engine``, default toWARN
.
OTHER_LOG_LEVEL
: Log level for other modules, default toWARN
.
QGIS_SERVER_LOG_LEVEL
: Qgis server log level, default to2
,0
for verbose.
CPL_VSIL_CURL_USE_CACHE
: GDAL option, default toTRUE
.
CPL_VSIL_CURL_CACHE_SIZE
: GDAL option, default to128000000
.
CPL_VSIL_CURL_USE_HEAD
: GDAL option, default toFALSE
.
GDAL_DISABLE_READDIR_ON_OPEN
: GDAL option, default toTRUE
.