No project description provided
Project description
Ansible Env Vars
Extracts variables from the local environment and converts them to Ansible variables.
Install and Setup
Install: uv add [--dev] ans-env-loader
Then place an ans-env-vars.yaml and an env-loader.py into your Ansible playbooks root directory
as follows:
❯ tree
├── ansible.cfg
├── ans-env-vars.yaml
├── hosts.ini
├── playbook.yaml
└── vars_plugins
├── env-loader.py
❯ cat vars_plugins/env-loader.py
from ans_env_loader import VarsModule as VarsModule
❯ cat ans-env-vars.yaml
# Ansible var name is the same as the expected env var
- app_smtp_host
# Map Ansible var name to a different expected env var
- app_flask_secret: FLASK_SECRET
Dev
Copier Template
Project structure and tooling mostly derives from the Coppy, see its documentation for context and additional instructions.
This project can be updated from the upstream repo, see Updating a Project.
Project Setup
From zero to hero (passing tests that is):
-
Ensure host dependencies are installed
-
Start docker service dependencies (if applicable):
docker compose up -d -
Sync project virtualenv w/ lock file:
uv sync -
Configure pre-commit:
pre-commit install -
Run tests:
nox
Versions
Versions are date based. A bump action exists to help manage versions:
# Show current version
mise bump --show
# Bump version based on date, tag, and push:
mise bump
# See other options
mise bump -- --help
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ans_env_loader-0.20250626.1.tar.gz.
File metadata
- Download URL: ans_env_loader-0.20250626.1.tar.gz
- Upload date:
- Size: 43.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c48774999c14e8ae9ea2219c5d963a67dd66e410415e09fe92d29245040ada33
|
|
| MD5 |
cac82d03b22ad53d0713d654574c0376
|
|
| BLAKE2b-256 |
52a3f9506f550b235dc655ac7c3bdc198f0ffebb46f9292be4b37f8e1bdccc8b
|
Provenance
The following attestation bundles were made for ans_env_loader-0.20250626.1.tar.gz:
Publisher:
pypi.yaml on level12/ans-env-loader
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ans_env_loader-0.20250626.1.tar.gz -
Subject digest:
c48774999c14e8ae9ea2219c5d963a67dd66e410415e09fe92d29245040ada33 - Sigstore transparency entry: 251341098
- Sigstore integration time:
-
Permalink:
level12/ans-env-loader@ad61c645729c90bb38b681ab6306c1119d66436d -
Branch / Tag:
refs/tags/v0.20250626.1 - Owner: https://github.com/level12
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi.yaml@ad61c645729c90bb38b681ab6306c1119d66436d -
Trigger Event:
push
-
Statement type:
File details
Details for the file ans_env_loader-0.20250626.1-py3-none-any.whl.
File metadata
- Download URL: ans_env_loader-0.20250626.1-py3-none-any.whl
- Upload date:
- Size: 2.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fecddaf7794bdca13354d6ff8df42bb39c5bdf915343faa1cddfecb44096e575
|
|
| MD5 |
2b10ec1754bd5683c9f2bc54c4cc1b23
|
|
| BLAKE2b-256 |
d2c039ee3aa544f234bd8d4f79af3b33e4d1efa1f3e0e422f5b4679f2f987bc0
|
Provenance
The following attestation bundles were made for ans_env_loader-0.20250626.1-py3-none-any.whl:
Publisher:
pypi.yaml on level12/ans-env-loader
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ans_env_loader-0.20250626.1-py3-none-any.whl -
Subject digest:
fecddaf7794bdca13354d6ff8df42bb39c5bdf915343faa1cddfecb44096e575 - Sigstore transparency entry: 251341101
- Sigstore integration time:
-
Permalink:
level12/ans-env-loader@ad61c645729c90bb38b681ab6306c1119d66436d -
Branch / Tag:
refs/tags/v0.20250626.1 - Owner: https://github.com/level12
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi.yaml@ad61c645729c90bb38b681ab6306c1119d66436d -
Trigger Event:
push
-
Statement type: