Configuration Settings

Configuration can be done either by using a toml configuration file, environnement variable or secret files.

The configuration framework is based on the pydantic settings package which provides strong validation for configuration data.

Environment variables

The mapping of configuration values follows the following pattern:

  • Environment variable names are case-insensitive.

  • Environment variables must be prefixed with CONF_

  • Nested settings are separated by __ (double underscore)

  • List and dictionnaries are populated from environnement by treating the environnement variable’s value as JSON-encoded strinf.

Example:

Consider the following the toml configuration:

[logging]
level = "DEBUG"

[worker]
service_name = "MyService"
broker_host = "rabbitmq"
broker_backend = "redis:6370/0"

[processing]
workdir = "/qgis-workdir"

[processing.plugins]
paths = ["/qgis-plugins"]

[processing.projects.search_paths]
'/' = "/qgis-projects"

And the corresponding configuration with environment variables:

CONF_LOGGING__LEVEL=DEBUG
CONF_WORKER__SERVICE_NAME=MyService
CONF_WORKER__BROKER_HOST=rabbitmq
CONF_WORKER__BACKEND_HOST=redis:6379/0
CONF_PROCESSING__WORKDIR=/qgis-workdir
CONF_PROCESSING__PLUGINS__PATHS='["/qgis-plugins"]'
CONF_PROCESSING__PROJECTS__SEARCH_PATHS: '{"/":"/qgis-projects"}'

Secret files

Instead of using exposed environment variables or configuration files, values may be stored in files that contains a single value and where the name of the file is the configuration.

A common usecase is to allow for storing sensitive values in Docker encrypted secret files.

Configuration precedence

Configuration precedence is (by decreasing priority):

  • Configuration file

  • Environment variables

  • Secret files

  • Default values

Worker configuration

  1[logging]
  2level = "INFO"
  3
  4
  5# Worker configuration
  6# 
  7# Configure celery worker settings
  8# 
  9[worker]
 10#
 11# Celery amqp broker host
 12broker_host = "localhost"
 13broker_use_tls = false
 14#broker_user =   	# Optional
 15#broker_password =   	# Optional
 16#
 17# Celery redis backend host
 18backend_host = "localhost:6379/0"
 19backend_use_tls = false
 20#backend_password =   	# Optional
 21#
 22# Task hard time limit in seconds.
 23# The worker processing the task will be killed
 24# and replaced with a new one when this is exceeded.
 25# 
 26task_time_limit = 3600
 27#
 28# Grace period to add to the 'task_time_limit' value.
 29# The SoftTimeLimitExceeded exception will be raised
 30# when the 'task_time_limit' is exceeded.
 31# 
 32task_time_grace_period = 60
 33#
 34# Time (in seconds), for when after stored task tombstones will
 35# be deleted
 36# 
 37result_expires = 86400
 38#
 39# Concurrency
 40#
 41# The number of concurrent worker processes executing tasks.
 42#concurrency =   	# Optional
 43#
 44# Autoscale
 45#
 46# Activate concurrency autoscaling
 47#max_concurrency =   	# Optional
 48#
 49# Processes life cycle
 50#
 51# Maximum number of tasks a pool worker process can execute
 52# before it's replaced with a new one. Default is no limit.
 53# 
 54#max_tasks_per_child =   	# Optional
 55#
 56# Maximum consumed memory
 57#
 58# Maximum amount of resident memory, in kilobytes,
 59# that may be consumed by a worker before it will
 60# be replaced by a new worker.
 61# 
 62#max_memory_per_child =   	# Optional
 63#
 64# Name of the service
 65#
 66# Name used as location service name
 67# for initializing Celery worker.
 68# 
 69#service_name =   	# Required
 70#
 71# Service short title
 72title = ""
 73#
 74# Service description
 75description = ""
 76#
 77# Cleanup interval
 78#
 79# Interval is seconds between two cleanup of expired jobs.
 80# The minimun is 300s (5mn).
 81# 
 82cleanup_interval = 3600
 83#
 84# Reload watch file
 85#
 86# The file to watch for reloading processing plugins.
 87# When the the modified time of the file is changed, processing
 88# providers are reloaded.
 89# The restart is graceful, all running jobs are terminated normally.
 90# 
 91#reload_monitor =   	# Optional
 92#
 93# Hide presence versions
 94#
 95# Hide version details in presence.
 96# This may be useful when you do not want to
 97# display versions of libraries and OS for security
 98# reasons.
 99# 
100hide_presence_versions = false
101
102#
103[worker.broker_tls]
104#
105# CA file
106#cafile =   	# Optional
107#
108# TLS  certificat
109#
110# Path to the TLS cert file
111#certfile =   	# Optional
112#
113# TLS key file
114#
115# Path to the TLS key file
116#keyfile =   	# Optional
117
118#
119[worker.backend_tls]
120#
121# CA file
122#cafile =   	# Optional
123#
124# TLS  certificat
125#
126# Path to the TLS cert file
127#certfile =   	# Optional
128#
129# TLS key file
130#
131# Path to the TLS key file
132#keyfile =   	# Optional
133
134#
135[worker.security]
136#cert_store =   	# Required
137#keyfile =   	# Required
138#certfile =   	# Required
139
140#
141[worker.scheduler]
142#
143# Enable scheduler
144#
145# Enable embedded scheduler.
146# Prefer scheduler as a service if more
147# than one worker node is used.
148# 
149enabled = false
150#
151# Max interval
152#
153# Max seconds to sleep between schedule iterations.
154#max_interval =   	# Optional
155#
156# Scheduler database path
157#
158# Path to the schedule database.
159# Defaults to `celerybeat-schedule` (from Celery doc).
160# 
161#database =   	# Optional
162
163#
164# Service related links
165#
166[[worker.links]]
167#rel =   	# Optional
168#mime_type =   	# Optional
169title = ""
170#description =   	# Optional
171#length =   	# Optional
172templated = false
173#hreflang =   	# Optional
174#href =   	# Required
175
176
177# Configure storage for processing data
178[storage]
179#
180# Storage module
181#
182# The module implementing storage accesses for
183# job's files.
184# 
185storage_class = "qjazz_processes.worker.storages.local.LocalStorage"
186config = {}
187
188#
189# Callbacks
190#
191# Define a mapping between a uri scheme and a handler for that
192# scheme.
193# 
194#
195# Example:
196#
197# [callbacks.https]
198# handler = "qjazz_processes.callbacks.Http",
199# 
200[callbacks.'key']
201#
202# Enable callback
203enabled = true
204#
205# Callback module
206#
207# The callback handler import string
208#handler =   	# Required
209#
210# Callback configuration
211config = {}
212
213
214[processing]
215#
216# Working directory
217#
218# Parent working directory where processes are executed.
219# Each processes will create a working directory for storing
220# result files and logs.
221# 
222#workdir =   	# Required
223#
224# Internal qgis providers exposed
225#
226# List of exposed QGIS processing internal providers.
227# NOTE: It is not recommended exposing all providers like
228# `qgis` or `native`, instead provide your own wrapping
229# algorithm, script or model.
230# 
231exposed_providers = ["script","model"]
232#
233# Expose deprecated algorithms
234#
235# Expose algorithm wich have the `Deprecated`
236# flag set.
237# 
238expose_deprecated_algorithms = true
239#
240# Default vector file extension
241#
242# Define the default vector file extensions for vector destination
243# parameters. If not specified, then the QGIS default value is used.
244# 
245default_vector_file_ext = "fgb"
246#
247# Default raster file extension
248#
249# Define the default raster file extensions for raster destination
250# parameters. If not specified, then the QGIS default value is used.
251# 
252#default_raster_file_ext =   	# Optional
253#
254# Force ellipsoid imposed by the source project
255#
256# Force the ellipsoid from the src project into the destination project.
257# This only apply if the src project has a valid CRS.
258# 
259adjust_ellipsoid = false
260#
261# Set default CRS
262#
263# Set the CRS to use when no source map is specified.
264# For more details on supported formats see the GDAL method
265# 'GdalSpatialReference::SetFromUserInput()'
266# 
267default_crs = "urn:ogc:def:crs:OGC:1.3:CRS84"
268#
269# Advertised services urls
270#
271# Url template used for OGC services references.
272advertised_services_url = "ows:$jobId/$name"
273#
274# Public download url
275#
276# Url template for downloading resources.
277# This is the public base url that will be seen in
278# referenced responses.
279# This url will need to be translated by the front end
280# executor to an effective download url.
281# 
282store_url = "${public_url}/jobs/$jobId/files/$resource"
283#
284# Use destination input as sink
285#
286# Allow input value as sink for destination layers.
287# This allow value passed as input value to be interpreted as
288# path or uri sink definition. This enable passing any string
289# that QGIS may use a input source but without open options except for the
290# 'layername=<name>' option.
291# 
292# NOTE: Running concurrent jobs with this option may result in unpredictable
293# behavior.
294# 
295# For that reason it is considered as an UNSAFE OPTION and you should never enable
296# this option if you are exposing the service publicly.
297# 
298# File path inputs prefixed with '/' will correspond to path located in the root
299# directory specified by the `raw_destination_root_path` option.
300# Otherwise, they will be stored in the job folder.
301# 
302raw_destination_input_sink = false
303#
304# Raw destination root path
305#
306# Specify the root directory for storing destination layers files when
307# the `raw_destination_input_sink` option is enabled.
308# If not specified, files will be stored in the job folder.
309# 
310#raw_destination_root_path =   	# Optional
311#
312# Project cache size
313#
314# The maximum number of projects in cache by process.
315max_cached_projects = 10
316#
317# Qgis settings
318#
319# Qgis settings override.
320# Use the syntax '<section>/<path>' for keys.
321# Not that values defined here will override those
322# from QGIS3.ini file."
323# 
324qgis_settings = {}
325#
326# Download timeout
327#
328# Download timeout is seconds for reference values
329download_timeout = 20.0
330
331#
332# Projects configuration
333#
334# Projects and cache configuration
335#
336[processing.projects]
337#
338# Trust layer metadata
339#
340# Trust layer metadata.
341# Improves layer load time by skipping expensive checks
342# like primary key unicity, geometry type and
343# srid and by using estimated metadata on layer load.
344# Since QGIS 3.16
345# 
346trust_layer_metadata = false
347#
348# Disable GetPrint requests
349#
350# Don't load print layouts.
351# Improves project read time if layouts are not required,
352# and allows projects to be safely read in background threads
353# (since print layouts are not thread safe).
354# 
355disable_getprint = false
356#
357# Force read only mode
358#
359# Force layers to open in read only mode."
360# This is the default, unless you have really good reason
361# to open layers in write mode.
362# Note that some handlers (like S3) do not support opening layers
363# in write mode.
364# 
365force_readonly_layers = true
366#
367# Ignore bad layers
368#
369# Allow projects to be loaded with event if it contains
370# layers that cannot be loaded.
371# Note that the 'dont_resolve_layers flag' trigger automatically
372# this option.
373# 
374ignore_bad_layers = false
375#
376# Disable OWS advertised urls
377#
378# Disable ows urls defined in projects.
379# This may be necessary because Qgis projects
380# urls override proxy urls.
381disable_advertised_urls = false
382#
383# Scheme mapping definitions
384#
385# Defines mapping betweeen location base path and storage handler root url.
386# Resource path relative to location will be joined the the root url path.
387# In the case of Qgis storage, the handler is responsible for transforming
388# the result url into a comprehensive format for the corresponding
389# QgsProjectStorage implementation.
390# This is handled by the default storage implementation for Qgis native
391# project storage.
392# In case of custom QgsProjectStorage, if the scheme does not allow passing
393# project as path component, it is possible to specify a custom resolver function.
394# 
395search_paths = {}
396#
397# Allow direct path resolution
398#
399# Allow direct path resolution if there is
400# no matching from the search paths.
401# Uri are directly interpreted as valid Qgis project's path.
402# WARNING: allowing this may be a security vulnerabilty."
403# 
404allow_direct_path_resolution = false
405
406#
407# Project storage Handler configurations
408#
409# Configure storage handlers.
410# The name will be used as scheme for project's search path
411# configuration.
412# 
413#
414# Example:
415#
416# [projects.search_paths]
417# "/public/location1/" = "postgres1://?dbname=mydatabase1"
418# "/public/location2/" = "postgres1://?dbname=mydatabase2"
419# 
420# [projects.handlers.postgres1]
421# handler_class = qjazz_cache.handlers.postgresql.PostgresHandler
422# 
423# [projects.handlers.postgres1.config]
424# uri = "postgresql://user@host/?schema=myschema"
425# 
426#
427[processing.projects.handlers.'key']
428#handler =   	# Required
429config = {}
430
431#
432# Plugin configuration
433#
434[processing.plugins]
435#
436# Plugin paths
437#
438# The list of search paths for plugins.
439# Qgis plugins found will be loaded according to
440# the 'install' list.
441# If the list is empty, the 'QGIS_PLUGINPATH'
442# variable will be checked.
443paths = []
444#
445# Installable plugins
446#
447# The list of installable plugins.
448# Note: if the plugin directory contains other plugins
449# plugins not in the list will NOT be loaded !
450# The Plugins will be installed at startup
451# if the 'install_mode' is set to 'auto'.
452# Note that an empty list means what it is:
453# i.e, *no* installed plugins.
454#install =   	# Optional
455#
456# Plugin installation mode
457#
458# If set to 'auto', plugins installation
459# will be checked at startup. Otherwise,
460# Installation will be done from already available
461# plugins.
462install_mode = "external"
463#
464# Enable processing scripts
465#
466# Enable publication of processing scripts
467enable_scripts = true
468#
469# Extra builtins providers
470#
471# Load extra builtin processing providers
472# such as 'grass' and 'otb'.
473extra_builtin_providers = []
474#
475# Path to plugin manager executable
476#
477# The absolute path to the qgis-plugin_manager executable
478# that will be used for installing plugin in automatic mode.
479plugin_manager = "/usr/local/bin/qgis-plugin-manager"
480
481#
482# TLS Certificates
483#
484# TLS credentials to use for references inputs
485#
486[processing.certificats]
487#
488# CA file
489#cafile =   	# Optional
490#
491# TLS  certificat
492#
493# Path to the TLS cert file
494#certfile =   	# Optional
495#
496# TLS key file
497#
498# Path to the TLS key file
499#keyfile =   	# Optional
500
501#
502# Qgis network
503#
504[processing.network]
505#
506# Transfer timeout in ms
507#
508# Transfers are aborted if no bytes are transferred before
509# the timeout expires.
510# If set to 0, the timeout is disobled.
511# Default value is set to 10000 milliseconds.
512# 
513transfer_timeout = 10000
514#
515# Trace network activity
516trace = false
517#
518# Global cache policy
519#
520# Set a global cache policy for all requests"
521# If set, this will override requests cache policy".
522# 
523#cache_policy =   	# Optional
524
525#
526# Domain policies
527#
528# Set per domain policy
529#
530[processing.network.domain_policy.'key']
531#
532# Cache load control
533#
534# Override QNetworkRequest::CacheLoadControl for request.
535#cache_policy =   	# Optional
536#
537# Transfer timeout in ms
538#transfer_timeout =   	# Optional

Server configuration

  1[logging]
  2level = "INFO"
  3
  4
  5# OAPI configuration
  6[oapi]
  7title = "Qjazz-Processes"
  8description = "Publish Qgis processing algorithms as OGC api processes"
  9
 10
 11# Defining job realm allow filtering job's requests by a token that is
 12# set by the client when requesting task execution (see description below).
 13# 
 14[job_realm]
 15#
 16# Enable job realm header
 17#
 18# When enabled, use the 'X-Job-Realm' http header
 19# as a client identification token for retrieving jobs status and results.
 20# 
 21enabled = false
 22#
 23# Admininistrator realm jobs tokens
 24#
 25# Define catch all tokens for listing and retrieve status and results
 26# for all jobs.
 27# 
 28admin_tokens = []
 29
 30
 31# Configure access policy
 32[access_policy]
 33#
 34# Access policy module
 35#
 36# The module implementing the access policy for
 37# processes execution.
 38# 
 39policy_class = "qjazz_processes.server.policies.default.DefaultAccessPolicy"
 40config = {}
 41
 42
 43[http]
 44#
 45# Interfaces to listen to
 46listen = ["127.0.0.1",9180]
 47#
 48# Use tls
 49use_tls = false
 50#
 51# CORS origin
 52#
 53# Allows to specify origin for CORS. If set 'all' will set
 54# Access-Control-Allow-Origin to '*'; 'same-origin' return
 55# the same value as the 'Origin' request header.
 56# A url may may be specified, restricting allowed origin to
 57# this url.
 58# 
 59cross_origin = "all"
 60#
 61# Service update interval
 62#
 63# Interval in seconds between update of available services
 64update_interval = 30
 65#
 66# Backend request timeout
 67timeout = 20
 68
 69#
 70# TLS configuration
 71#
 72[http.tls]
 73#
 74# CA file
 75#cafile =   	# Optional
 76#
 77# TLS  certificat
 78#
 79# Path to the TLS cert file
 80#certfile =   	# Optional
 81#
 82# TLS key file
 83#
 84# Path to the TLS key file
 85#keyfile =   	# Optional
 86
 87#
 88[http.proxy]
 89#
 90# Enabled Forwarded headers
 91#
 92# Enable proxy headers resolution.
 93# Include support for 'Forwarded' headers
 94# and 'X-Forwarded' headers if allow_x_headers is
 95# enabled."
 96# 
 97enable = false
 98#
 99# Support for 'X-Forwarded' headers
100allow_x_headers = false
101
102
103[executor]
104#
105# Message expiration timeout
106#
107# The amount of time an execution message
108# can wait on queue before beeing processed
109# with asynchronous response.
110# 
111message_expiration_timeout = 600
112
113#
114[executor.celery]
115#
116# Celery amqp broker host
117broker_host = "localhost"
118broker_use_tls = false
119#broker_user =   	# Optional
120#broker_password =   	# Optional
121#
122# Celery redis backend host
123backend_host = "localhost:6379/0"
124backend_use_tls = false
125#backend_password =   	# Optional
126#
127# Task hard time limit in seconds.
128# The worker processing the task will be killed
129# and replaced with a new one when this is exceeded.
130# 
131task_time_limit = 3600
132#
133# Grace period to add to the 'task_time_limit' value.
134# The SoftTimeLimitExceeded exception will be raised
135# when the 'task_time_limit' is exceeded.
136# 
137task_time_grace_period = 60
138#
139# Time (in seconds), for when after stored task tombstones will
140# be deleted
141# 
142result_expires = 86400
143#
144# Concurrency
145#
146# The number of concurrent worker processes executing tasks.
147#concurrency =   	# Optional
148#
149# Autoscale
150#
151# Activate concurrency autoscaling
152#max_concurrency =   	# Optional
153#
154# Processes life cycle
155#
156# Maximum number of tasks a pool worker process can execute
157# before it's replaced with a new one. Default is no limit.
158# 
159#max_tasks_per_child =   	# Optional
160#
161# Maximum consumed memory
162#
163# Maximum amount of resident memory, in kilobytes,
164# that may be consumed by a worker before it will
165# be replaced by a new worker.
166# 
167#max_memory_per_child =   	# Optional
168
169#
170[executor.celery.broker_tls]
171#
172# CA file
173#cafile =   	# Optional
174#
175# TLS  certificat
176#
177# Path to the TLS cert file
178#certfile =   	# Optional
179#
180# TLS key file
181#
182# Path to the TLS key file
183#keyfile =   	# Optional
184
185#
186[executor.celery.backend_tls]
187#
188# CA file
189#cafile =   	# Optional
190#
191# TLS  certificat
192#
193# Path to the TLS cert file
194#certfile =   	# Optional
195#
196# TLS key file
197#
198# Path to the TLS key file
199#keyfile =   	# Optional
200
201#
202[executor.celery.security]
203#cert_store =   	# Required
204#keyfile =   	# Required
205#certfile =   	# Required
206
207#
208[executor.celery.scheduler]
209#
210# Enable scheduler
211#
212# Enable embedded scheduler.
213# Prefer scheduler as a service if more
214# than one worker node is used.
215# 
216enabled = false
217#
218# Max interval
219#
220# Max seconds to sleep between schedule iterations.
221#max_interval =   	# Optional
222#
223# Scheduler database path
224#
225# Path to the schedule database.
226# Defaults to `celerybeat-schedule` (from Celery doc).
227# 
228#database =   	# Optional
229
230
231# The storage configuration is used for configuring the
232# connections to storage backends used by workers.
233# 
234[storage]
235#
236# Allow insecure downloads
237#
238# If set to false, only TLS encrypted downloads are allowed
239allow_insecure_connection = true
240#
241# Download chunksize
242chunksize = 65536
243#
244# Download url expiration
245#
246# Download url expiration in seconds
247download_url_expiration = 3600
248
249#
250# TLS certifificats
251#
252# Certificats required for TLS downloads connections
253#
254[storage.tls]
255#
256# CA file
257#cafile =   	# Optional
258#
259# TLS  certificat
260#
261# Path to the TLS cert file
262#certfile =   	# Optional
263#
264# TLS key file
265#
266# Path to the TLS key file
267#keyfile =   	# Optional
268
269
270#[store]
271#
272# S3/Minio endpoint
273#endpoint = "localhost:9000"
274#cafile =   	# Optional
275#access_key =   	# Required
276#secret_key =   	# Required
277#
278# Enable TLS
279#enable_tls = false
280#
281# Check certificat
282#check_certificat = true
283#region =   	# Optional
284#
285# Access TTL
286#
287# Lifetime given to a job store access since the job was scheduled
288# for execution; the access credentials will no be
289# longer valid after this time.
290# 
291#access_ttl = 86400

Callbacks

Callbacks requirements are specified by OGC standards.

It allows to set up a push based mechanism for processes results to others services.

Originally, only http POST requests are considered but Qjazz processes support arbitrary uri schemes.

Callbacks handlers are declared in worker configuration under the [callbacks."<scheme,...>"] section along with their configuration and the import string to the class implementing the callback support.

Qjazz implement natively ‘http’ and ‘mailto’ scheme callbacks.

HTTP Callback configuration

  1[callbacks]
  2
  3#
  4[callbacks.mailto]
  5#
  6# Enable callback
  7enabled = true
  8handler = "qjazz_processes.callbacks.MailTo"
  9
 10#
 11[callbacks.mailto.config]
 12#
 13# SMTP host
 14#smtp_host =   	# Required
 15#
 16# SMTP port
 17smtp_port = 587
 18#
 19# SMTP login
 20#smtp_login =   	# Optional
 21#
 22# SMTP password
 23smtp_password = ""
 24#
 25# TLS/SSL
 26smtp_tls = false
 27#
 28# From address
 29#mail_from =   	# Required
 30#
 31# Format
 32#
 33# The format of the e-mail body
 34body_format = "plain"
 35#
 36# Attach results
 37#
 38# Send job results as attachment
 39send_results_as_attachment = false
 40#
 41# Request timeout
 42#
 43# The request timeout value in seconds
 44timeout = 5
 45#
 46# Debug mode
 47debug = false
 48
 49#
 50# Subject and body to set on success notification
 51# If a subject is provided then it will override the configuration value.
 52# 
 53#
 54[callbacks.mailto.config.content_success]
 55subject = "[Qjazz:$service] Job $process successfull"
 56body = '''
 57The job $jobid ($process) has been executed with success.
 58'''
 59
 60#
 61# Subject and body to set on failed notification.
 62# If a subject is provided then it will override the configuration value.
 63# 
 64#
 65[callbacks.mailto.config.content_failed]
 66subject = "[QJazz:$service] Job $process failed"
 67body = '''
 68The job $jobid ($process) has failed.
 69'''
 70
 71#
 72# Subject and body to set on inProgresss notification.
 73# If a subject is provided then it will override the configuration value.
 74# 
 75#
 76[callbacks.mailto.config.content_in_progress]
 77subject = "[QJazz:$service] Job $process started"
 78body = '''
 79The job $jobid ($process) has started.
 80'''
 81
 82#
 83[callbacks.mailto.config.acl]
 84#
 85# Authorization order
 86#
 87# Set the order of evaluation of allow and deny directives:
 88# - Allow: allow by default  except thoses in deny then
 89#   put back those in deny with the allow directive.
 90# - Deny: deny by default  except thoses in allow then deny
 91#   those in allow with the deny directive.
 92# 
 93order = "Allow"
 94#
 95# Allowed addresses
 96#
 97# List of allowed hosts. An host may be a IP addresse at IP range
 98# in CIDR format or a FQDN or FQDN suffix starting with a dot (and
 99# an optional '*').
100# 
101#
102# Example:
103#
104# allow = [
105#     "foo.bar.com",
106#     "*.mydomain.com",
107#     "192.168.0.0/24",
108#     "192.168.1.2",
109# ]
110# 
111allow = []
112#
113# Forbidden addresses
114#
115# List of forbidden hosts in the same format as for 'allow' list.
116deny = []

Note

For serving both http and https use [callbacks."http,https"].

MailTo Callback configuration

Allow sending e-mail with callbacks.

  1[callbacks]
  2
  3#
  4[callbacks.mailto]
  5#
  6# Enable callback
  7enabled = true
  8handler = "qjazz_processes.callbacks.MailTo"
  9
 10#
 11[callbacks.mailto.config]
 12#
 13# SMTP host
 14#smtp_host =   	# Required
 15#
 16# SMTP port
 17smtp_port = 587
 18#
 19# SMTP login
 20#smtp_login =   	# Optional
 21#
 22# SMTP password
 23smtp_password = ""
 24#
 25# TLS/SSL
 26smtp_tls = false
 27#
 28# From address
 29#mail_from =   	# Required
 30#
 31# Format
 32#
 33# The format of the e-mail body
 34body_format = "plain"
 35#
 36# Attach results
 37#
 38# Send job results as attachment
 39send_results_as_attachment = false
 40#
 41# Request timeout
 42#
 43# The request timeout value in seconds
 44timeout = 5
 45#
 46# Debug mode
 47debug = false
 48
 49#
 50# Subject and body to set on success notification
 51# If a subject is provided then it will override the configuration value.
 52# 
 53#
 54[callbacks.mailto.config.content_success]
 55subject = "[Qjazz:$service] Job $process successfull"
 56body = '''
 57The job $jobid ($process) has been executed with success.
 58'''
 59
 60#
 61# Subject and body to set on failed notification.
 62# If a subject is provided then it will override the configuration value.
 63# 
 64#
 65[callbacks.mailto.config.content_failed]
 66subject = "[QJazz:$service] Job $process failed"
 67body = '''
 68The job $jobid ($process) has failed.
 69'''
 70
 71#
 72# Subject and body to set on inProgresss notification.
 73# If a subject is provided then it will override the configuration value.
 74# 
 75#
 76[callbacks.mailto.config.content_in_progress]
 77subject = "[QJazz:$service] Job $process started"
 78body = '''
 79The job $jobid ($process) has started.
 80'''
 81
 82#
 83[callbacks.mailto.config.acl]
 84#
 85# Authorization order
 86#
 87# Set the order of evaluation of allow and deny directives:
 88# - Allow: allow by default  except thoses in deny then
 89#   put back those in deny with the allow directive.
 90# - Deny: deny by default  except thoses in allow then deny
 91#   those in allow with the deny directive.
 92# 
 93order = "Allow"
 94#
 95# Allowed addresses
 96#
 97# List of allowed hosts. An host may be a IP addresse at IP range
 98# in CIDR format or a FQDN or FQDN suffix starting with a dot (and
 99# an optional '*').
100# 
101#
102# Example:
103#
104# allow = [
105#     "foo.bar.com",
106#     "*.mydomain.com",
107#     "192.168.0.0/24",
108#     "192.168.1.2",
109# ]
110# 
111allow = []
112#
113# Forbidden addresses
114#
115# List of forbidden hosts in the same format as for 'allow' list.
116deny = []