Skip to main content

Library for one endpoint config and credentials managment

Project description

Sitri Configuration Library

Build Status codecov PyPI Read the Docs CodeFactor

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.contrib.system import SystemCredentialProvider, SystemConfigProvider
from sitri import Sitri

conf = Sitri(config_provider=SystemConfigProvider(prefix="basics"),
             credential_provider=SystemCredentialProvider(prefix="basics"))

System provider use system environment for get config and credential 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.4.21.tar.gz (6.3 kB view details)

Uploaded Source

Built Distribution

sitri-0.4.21-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file sitri-0.4.21.tar.gz.

File metadata

  • Download URL: sitri-0.4.21.tar.gz
  • Upload date:
  • Size: 6.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/0.12.17 CPython/3.7.1 Linux/4.15.0-1040-gcp

File hashes

Hashes for sitri-0.4.21.tar.gz
Algorithm Hash digest
SHA256 eb79d4740751d7c0265ce3aaa2fce03883dac0c929aae1f35797348762336848
MD5 8b6685546a766a64a4643aae54e3cc95
BLAKE2b-256 316b67e12a06914de61381abed1972a4e594dc827624da9f24161c880fb90400

See more details on using hashes here.

File details

Details for the file sitri-0.4.21-py3-none-any.whl.

File metadata

  • Download URL: sitri-0.4.21-py3-none-any.whl
  • Upload date:
  • Size: 8.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/0.12.17 CPython/3.7.1 Linux/4.15.0-1040-gcp

File hashes

Hashes for sitri-0.4.21-py3-none-any.whl
Algorithm Hash digest
SHA256 d1b15dce216a7cf4f1a4092be9417e3837ab9b00f2d23b224688998b14c6a987
MD5 ae69048c87e40b6b3e3fde06a2a426e6
BLAKE2b-256 529f63fededd59bb0aabf2a4625b14d51c050753df202c07fc02329861f4a93d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page