read secrets from terraform tfvars files
Project description
python-tfvars
read secrets from terraform tfvars
This module will read variables from terraform tfvars files to facilitate the usage of python scripts from terraform resources.
Currently we do not support json format.
basic usage
Assuming a terraform.tfvars file as follows:
token = "some_token"
in your python script:
import tfvars
tfv = tfvars.LoadSecrets()
print(tfv["token"])
optionally specify a file location:
tfv = tfvars.LoadSecrets("../dev.auto.tfvars")
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
python-tfvars-0.1.0.tar.gz
(3.4 kB
view hashes)
Built Distribution
Close
Hashes for python_tfvars-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 455134192d3ca735fe83ac26fb70be638170b2a8dd82ec6a94b30746f589bd74 |
|
MD5 | 8cfaf11975b3896ff2f8ec791fbaeff5 |
|
BLAKE2b-256 | aa36c9a67ea161969c5b4baf7d48769c5f69a627266813fe0752bb856c468428 |