Skip to main content

Call child process with custom environment

Project description

envfrom

Kubernetes Secrets or ConfigMap are commonly used to run apps deployed in pods. But what about running this app locally with those same variables ? envfrom meet this need among others.

Installation

pip install envfrom

Usage

usage: envfrom [-h] {cli,dir,kube} ... child

Call child process with custom environment

positional arguments:
  {cli,dir,kube}  env source
    cli           Dict values: FOO=BAR BAR=FOO
    dir           Set environment according to files in a specified path
    kube          Mirror specified kubernetes ressource volume keys (decoded)
  child           child process

optional arguments:
  -h, --help      show this help message and exit

Example

Assuming that you already have the following secret created on your default namespace :

apiVersion: v1
kind: Secret
metadata:
  name: mysecret
type: Opaque
data:
  username: YWRtaW4=

Running :

env -i envfrom kube secrets mysecret env

Should output :

username=admin

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

envfrom-0.0.1.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

envfrom-0.0.1-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file envfrom-0.0.1.tar.gz.

File metadata

  • Download URL: envfrom-0.0.1.tar.gz
  • Upload date:
  • Size: 3.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.5.7

File hashes

Hashes for envfrom-0.0.1.tar.gz
Algorithm Hash digest
SHA256 b8d65d3322aed403ebbbce9410d9dbd609414a23a66a488e562f78b2521e456a
MD5 f38c3dae5d05ae845a280c71a07ad410
BLAKE2b-256 b094e5820fcf94a9340efe5e72b6b5c9e23c95a6d514d7eb4033d8ea284849f9

See more details on using hashes here.

File details

Details for the file envfrom-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: envfrom-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.5.7

File hashes

Hashes for envfrom-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a0a9fa486dfb8e62fbde4a3700230db293ece674fac791e087fcfa20fa344468
MD5 d742820cd9b8588b03d02d00241560b9
BLAKE2b-256 87bd51752d51673e6903f42c4d890fe03bf2013fdfd985fe95c766c9f017f389

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