Ensure you're running at least Python 3.8.0 to get the latest version of Sovereign
1 2$ python --version Python 3.8.2
If you haven't done so already, you can install Sovereign via pip
1 2python -m pip install sovereign
The main things you'll need in order to run Sovereign are:
Start by creating an somewhat empty YAML configuration file at the location /etc/sovereign.yaml
1 2sources: [] templates: {}
Throughout the upcoming documentation you may see references to "Loadable paths"
These are paths that Sovereign uses to dynamically include data in configuration.
They are specified in the following way:
1 2protocol: <type of loader used> serialization: <serializer used to decode the data> path: <location of the data>
Most sections that ask you to use a loadable path will provide an example.
File Type | Description |
---|---|
file | Local file |
env | Environment Variable |
http/https | HTTP location |
module | Python module path |
python | Raw Python code |
pkgdata | Python Package Data |
s3 | S3 bucket |
inline | Inline data |
Serializer | Behavior |
---|---|
yaml | yaml.safe_load(data) |
json | json.loads(data) |
orjson | orjson.loads(data) |
ujson | ujson.loads(data) |
jinja | jinja2.Environment().from_string(data) |
jinja2 | jinja2.Environment().from_string(data) |
string | str(data) |
raw | data |
Rate this page: