Skip to main content

loadcredential

This is a simple python package for interfacing with systemd's LoadCredential mechanism. It allows reading secrets from the credentials directory, with a fallback on environment variables if needed.

Usage

Basic usage

from loadcredential import Credentials

credentials = Credentials()

secret1 = credentials["SECRET_1"]

Changes

v1.1 (2024-05-10)

  • Added credentials.get(key, default=None) which returns a default value and does not raise an error when the key is absent
  • Added credentials.get_json(key, default = None) which treats the imported secret as json data

v1.0 (2024-05-09)

Initial version

Metadata

Release files for loadcredential 1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for loadcredential 1.3
File Size Uploaded
loadcredential-1.3.tar.gz 3.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for loadcredential 1.3
File Interpreter ABI Platform
loadcredential-1.3-py3-none-any.whl Python 3 none any Details

Total release size: 7.7 kB

Release files / loadcredential-1.3.tar.gz

Download URL loadcredential-1.3.tar.gz
Size 3.4 kB
Tags Source
SHA-256 checksum
How to use checksums
2b0061b5dea739177f5cf675fb07546b4689909886291713c78ed9ffabf0f25c
BLAKE2b-256 checksum
How to use checksums
033091b8c259d2f384f7491f9565f1ced3629227daa2230555f4817609faaa99
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.11.9

Release files / loadcredential-1.3-py3-none-any.whl

Download URL loadcredential-1.3-py3-none-any.whl
Size 4.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0980e332db85c93808dade21da18c008b2191f1ac90fe8f04365e9c4c8ddb3c0
BLAKE2b-256 checksum
How to use checksums
80a5630dde382b5c54b2bac50bf65b20aa98169252726ef5e22f5dfb018ac038
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.11.9

Release history Release notifications | RSS feed

This release

1.3 This release

2 release files

1.1

2 release files

1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page