click to read first article about this package
a more efficient, automated, and developer-friendly approach, allowing them to define deployment environment requirements using simple JSON or YAML descriptions.
Specify the exact conditions under which a container can run, mitigating compatibility issues and enforcing security standards seamlessly…
This environment description can either be one or multiple files and can also be a combination for each type of environment…
$ pip install env_should_be
env_should_be -fs --description /path/to/description/db.yml /path/to/description/app.json --env-file /path/to/.env --callback ./notify_admin.bash
examples
a number of example should be available under this link
or just do a
env_should_be --help
env_should_be [-h] -d DESCRIPTION [DESCRIPTION ...] [-fs FAIL_SILENTLY] [-e ENV_FILE] [-cb CALLBACK]
How should your environment be?
options:
-d DESCRIPTION [DESCRIPTION ...], --description DESCRIPTION [DESCRIPTION ...]
<Required> either one or multiple paths for description files. (json/yml)
-fs FAIL_SILENTLY, --fail-silently FAIL_SILENTLY
<Optional> will return an exit status of 0 even if the description(s) fail to match the current env (still triggers the callback).
-e ENV_FILE, --env-file ENV_FILE
<Optional> not specifying a path to a specific env file to validate description(s) against, environment variables in the current shell will be loaded instead.
-cb CALLBACK, --callback CALLBACK
<Optional> a callback script to be executed an environment fails to match the a description. (still triggered on fail-silently)
full list of possible descriptions:
(
"boolean",
"length",
"min_length",
"max_length",
"regex",
"option",
"constant",
"is_int",
"is_str",
"is_float",
"is_number",
"is_greater_than_eq",
"is_lower_than_eq",
"is_http",
"is_https",
"is_ipv4",
"is_ipv6",
"is_email",
"is_uuid",
)
TODOs:
- better exceptions
- support required arg
- support callbacks
- example Dockerfiles for different base images (only flask for now)
- a more helpful readme
- collect/open issues
- support older python versions
- support different/more complex descriptions
- support setting default values
- ship a single executable ?
Metadata
Release files for env-should-be 0.2.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| env_should_be-0.2.7.tar.gz | 416.5 kB | Without provenance | Details for env_should_be-0.2.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| env_should_be-0.2.7-py3-none-any.whl | Python 3 | none | any | Details for env_should_be-0.2.7-py3-none-any.whl |
Total release size: 425.0 kB
Release files / env_should_be-0.2.7.tar.gz
| Download URL | env_should_be-0.2.7.tar.gz |
|---|---|
| Size | 416.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
aec0163cf41584aed665496490d5427741d8ec82388e36f164f2c28edf079f82
|
|
BLAKE2b-256 checksum How to use checksums |
d7f03137c20ae99d7c503ae0f3929d80cd1764a67bb903ddf25fe795c9d86a80
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.4
|
Release files / env_should_be-0.2.7-py3-none-any.whl
| Download URL | env_should_be-0.2.7-py3-none-any.whl |
|---|---|
| Size | 8.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b82199a6249bdeb7bf5a779b8ac0dcc0b4068297b6b401fadbac6118d707a4a6
|
|
BLAKE2b-256 checksum How to use checksums |
3463425f34d15fc0eefaa4bf079ca7b5c244b0bbce4d5cd28f01b295219e1d73
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.4
|
Security for env-should-be 0.2.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.