Library for one endpoint config and credentials managment
Project description
Sitri Configuration Library
Sitri - library for managing authorization and configuration data from a single object with possibly different or identical providers
Installation
poetry add sitri
or
pip3 install sitri
Basics with SystemProvider
from sitri.providers.contrib import SystemConfigProvider
from sitri import Sitri
conf = Sitri(
config_provider=SystemConfigProvider(prefix="basics"),
)
System provider use system environment for get config data. For unique - sitri lookup to "namespace" by prefix.
Example:
In console:
export BASICS_NAME=Huey
In code:
name = conf.get_config("name")
print(name) # output: Huey
Docs
Read base API references and other part documentation on https://sitri.readthedocs.io/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
sitri-0.10.0.tar.gz
(9.1 kB
view details)
Built Distribution
sitri-0.10.0-py3-none-any.whl
(15.4 kB
view details)
File details
Details for the file sitri-0.10.0.tar.gz
.
File metadata
- Download URL: sitri-0.10.0.tar.gz
- Upload date:
- Size: 9.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.4 CPython/3.8.6 Linux/5.4.0-1031-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a9f36ad760bb04acb9c93476d3773c528b73e39ddb189fba2dde45b14016100e |
|
MD5 | 6dde25bfac7582c8e0ab293a2cf7f7fe |
|
BLAKE2b-256 | cf2c6644422a1700de5f269f08367d2f8423ac42545a7e6ce9fdb55ee8c121b0 |
File details
Details for the file sitri-0.10.0-py3-none-any.whl
.
File metadata
- Download URL: sitri-0.10.0-py3-none-any.whl
- Upload date:
- Size: 15.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.4 CPython/3.8.6 Linux/5.4.0-1031-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 51ff7540a59ed234753515bd4ca37f3b8b5dbdd9ff140c4fe1d99a28699544f3 |
|
MD5 | f1609549abdaed5ce741ae34f41349e3 |
|
BLAKE2b-256 | a28487d3a254596f521e4ac321b32221389029d267dcbb0a935b255f6e3d02b0 |