(Tries to) parse AWS CloudFormation’s intrinsic functions in the template.
Quick Start
First, install the library:
pip install aws-parsecf
Then, from a Python interpreter:
import aws_parsecf
with open('/path/to/cloudformation.json', 'r') as f:
print(aws_parsecf.load_json(f))
Note that some of the intrinsic functions require a configured environment (like "Fn::GetAZs"), so if you don’t have it set:
aws configure
Usage
3 simple methods:
aws_parsecf.load_json(stream, region)
aws_parsecf.loads_json(string, region)
aws_parsecf.load_yaml(stream_or_string, region)
region is optional, and defaults to the region you specified when using aws configure. If you didn’t specify a default region in aws configure, or you want to override it, you should specify your region:
aws_parsecf.load_json(stream, region='us-west-1')
If your stack is parameterized, the default values will be used along with possibly supplying parameters:
aws_parsecf.load_json(stream, region, {'DomainName': "aws.parsecf.com"})
Contributing
Running tests:
./setup.py test
Missing pieces:
Support YAML short form.
You know the drill, PR!
Metadata
Release files for aws-parsecf 1.1.0
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 | |
|---|---|---|---|---|
| aws-parsecf-1.1.0.tar.gz | 8.0 kB | Without provenance | Details |
Release files / aws-parsecf-1.1.0.tar.gz
| Download URL | aws-parsecf-1.1.0.tar.gz |
|---|---|
| Size | 8.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
752f3bfcd242a163b7ec21eed5b75595f61626d7cfada2be6105d7038357a14d
|
|
BLAKE2b-256 checksum How to use checksums |
970360a863cbcc6531c1340a4e36b49f3fa2b4d93119ec8834121038ab485edf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for aws-parsecf 1.1.0
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.