-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathsupa.env
120 lines (105 loc) · 4.55 KB
/
supa.env
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
# Everything configurable in SuPA is listed in this file. Simple variable
# expansion a la POSIX is supported.
#
# The configuration variables can also be set as environment variables.
#
# $ export grpc_max_workers=8
#
# All configuration variables are case sensitive, even when used as environment
# variables, and written using "snake case" (lower case with "_" on word
# boundaries).
#
# In addition to this file and environment variables, the various sub commands
# of the `supa` command line tool accept arguments that can configure the same
# settings, though only when applicable to the sub command currently selected.
# *IMPORTANT*: Command line arguments use `-` instead of underscores in their
# names.
#
# The order of precedence of all these different ways of configuring the same
# configuration variable is (from high to low):
#
# 1. command line argument (eg: supa serve --grpc-max-workers=8)
# 2. environment variable (eg: grpc_max_workers=8 supa serve)
# 3. this file (`supa.env`)
# 4. default value in code (eg: when configuration variable is absent from
# `supa.env` or when of form `grpc_max_workers=${grpc_max_workers}`
# Application wide settings
#==========================
# ``WAL`` massively improves SQLite's concurrency; it allows DB READS while a
# single WRITE is in progress. However, it does not work properly over
# networked file systems (eg NFS). When using Kubernetes to deploy SuPA it is
# probably best to only use ``WAL`` in combination with a local volume (See:
# https://kubernetes.io/docs/concepts/storage/volumes/#local) If this is not an
# option, set ``database_journal_mode`` to ``TRUNCATE`` or ``DELETE`` (in order
# of preference)
#
# See also: https://sqlite.org/pragma.html#pragma_journal_mode
#
#database_journal_mode=WAL
# Specify the location of the database file. Resolving the actual location
# follows the following algorithm: If ``database_file`` is an absolute path, we
# are done. Otherwise determine if SuPA was installed normally or in editable
# mode/development mode. In case of the former resolve ``database_file``
# relative to ``<venv_dir>/var/db`` In case of the latter resolve
# ``database_file`` relative to the project root.
#
#database_file=supa.db
# Subcommand specific settings:
#===============================
# Subcommand: ``serve``
#----------------------
#grpc_server_max_workers=8
# The host and port SuPA is listening on.
grpc_server_insecure_host=localhost
grpc_server_insecure_port=50051
# The host and port the Requester Agent/PolyNSI is listening on.
grpc_client_insecure_host=localhost
grpc_client_insecure_port=9090
# In addition to serving gRPC requests, SuPA does a fair amount of background
# processing. This all happens under the control of a scheduler. The scheduler
# has a number of workers it can submit jobs to. This setting configures that
# number. In general it is best to keep this number equal or slightly higher
# than the number of ``grpc_max_workers`` (see below)
#scheduler_max_workers=12
# Name of the domain SuPA is responsible for.
domain=example.domain:2001
# Name of the network SuPA is responsible for.
topology=topology
# How long the topology is considered fresh before it is queried again through backend.topology()
#topology_freshness=60
# Use the SuPA CLI to edit STP's or fetch them through backend.topology()
#manual_topology=false
# Name of NRM backend module to load.
# The module should contain a class Backend derived from BaseBackend that can
# be used to override any of the SuPA <-> NRM interface methods,
# see src/supa/nrm/backend.py.
backend=
# Set log level to DEBUG (default), INFO, WARNING, ERROR or CRITICAL
log_level=INFO
# Time to wait in seconds before a Reserve call is timedout waiting for a ReserveCommit
#reserve_timeout=120
# NSA Discovery and Topology document configuration
#
# Host and port the document server is deployed on
document_server_host=localhost
document_server_port=4321
# NSA (external) URL (scheme, host, port, path) that is exposed in the discovery document
nsa_scheme=http
nsa_host=localhost
nsa_port=8080
nsa_provider_path=/provider
nsa_topology_path=/topology
nsa_discovery_path=/discovery
# Discovery docuement meta data
nsa_name="example.domain uPA"
nsa_owner_timestamp=19700101T000000Z
nsa_owner_firstname=Firstname
nsa_owner_lastname=Lastname
nsa_latitude=-0.374350
nsa_longitude=-159.996719
# Topology document meta data
topology_name=example.domain topology
# Healthcheck with call to Backend.topology() to assess NRM health
#healthcheck_with_topology=False
# the interval between health checks of all active connections in the NRM
#backend_health_check_interval=60