Tool to Install and Delete Cloudformation stacks easily.
Project description
A tool to Create and Delete Cloudformation stacks easily. Uses credentials from your ~/.aws/credentials file via boto3
Install
$ python3 -m pip install cfntool --user
Usage
cfn [-options]
options:
-h This help
-m parameter list string:
'something=somevalue,somethingelse=someothervalue'
-P profile to use to install the stack (not required if 'all' is chosen)
required options:
-a account name
-n name of stack
-p product tag
-t full path to Cloudformation template to use
All actions are mutually exclusive
you must provide one action
Actions:
-A install/update all accounts
-D delete named stack
-I install/update the named stack
-S status of named stack
if you provide more than one action, the last one on the
command line 'wins'.
Examples
Create a stack from a yaml template:
$ cfn -I -p mytool -P myaccountalias -m myaccount -n myStackName \
-t ~/src/mystack.yaml -m 'LambdaVersion=0.0.2,Owner=SRE'
06/03/2020 08:40:05 [INFO ] profile: myaccountalias, account id 1234567890, account name myaccount
06/03/2020 08:40:06 [ERROR] stack: myStackName does not exist
06/03/2020 08:40:06 [WARNI] stack myStackName does not exist (anymore)
06/03/2020 08:40:06 [INFO ] creating stack myStackName
06/03/2020 08:41:47 [INFO ] Stack myStackName is CREATE_COMPLETE
Status of named stack:
$ cfn -S -P myaccountalias -n myStackName 06/03/2020 08:42:14 [INFO ] stack myStackName is status: CREATE_COMPLETE
Delete a stack:
$ cfn -D -P myaccountalias -n myStackName 06/03/2020 08:44:39 [INFO ] Stack myStackName is CREATE_COMPLETE 06/03/2020 08:44:39 [WARNI] deleting stack: myStackName 06/03/2020 08:46:20 [ERROR] stack: myStackName does not exist 06/03/2020 08:46:20 [WARNI] stack myStackName does not exist (anymore) 06/03/2020 08:46:20 [INFO ] stack myStackName is status: None
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
cfntool-0.2.2.tar.gz
(6.9 kB
view details)
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 cfntool-0.2.2.tar.gz.
File metadata
- Download URL: cfntool-0.2.2.tar.gz
- Upload date:
- Size: 6.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.0.0 CPython/3.8.1 Linux/5.5.2-1-MANJARO
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
210136a0f7f7d8234f8f25a9dd43195af4dd94646d5a4496221a75c6cc7347eb
|
|
| MD5 |
20c8466eb15b68970548d3b9011e2b8f
|
|
| BLAKE2b-256 |
1ace0d689a47760c146674393a9a6eaac37f5a6f4790555e564fad76378e3128
|
File details
Details for the file cfntool-0.2.2-py3-none-any.whl.
File metadata
- Download URL: cfntool-0.2.2-py3-none-any.whl
- Upload date:
- Size: 7.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.0.0 CPython/3.8.1 Linux/5.5.2-1-MANJARO
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9aea5da6af4385aed7c4e4bdbb40a17023976cf3f42b3895ec6cca19dd629032
|
|
| MD5 |
85c0a2036bd3912292c9ef4752c872b4
|
|
| BLAKE2b-256 |
91b9ebe59b8b1a7e6d4fc785369aab0a0d68413989ee518fdfc1e40725b3bdde
|