Implode your AWS CDK Stack after set amount of time, save money, be happy!
Project description
cdk-time-bomb
Implode your AWS CDK Stack after set amount of time, save money, be happy!
Usage
In your Typescipt / Javascript AWS CDK project, add the cdk-time-bomb
module:
npm install cdk-time-bomb
Import the module and instantiate in your CDK Stack class. Specify a TTL Duration after which time the entire CloudFormation stack will self destroy:
import { SelfDestruct} from 'cdk-time-bomb';
const selfDestruct = new SelfDestruct(this, "selfDestructor", {
timeToLive: Duration.minutes(60)
});
Build and Deploy
Due to the large amount of dependencies required by jsii, use the docker image udondan/jsii-publish
to reliably and consistenly build this CDK construct.
docker run -it \
--workdir /workdir \
--volume $(pwd):/workdir \
--env VERSION=0.3.0 \
--env BUILD_SOURCE=true \
--env BUILD_PACKAGES=true \
--env NPM_TOKEN \
--env PYPI_TOKEN \
--env NUGET_TOKEN \
--env GITHUB_TOKEN \
--env GITHUB_REPOSITORY="${OWNER}/${REPOSITORY}" \
udondan/jsii-publish:0.8.3
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
cdk-time-bomb-1.50.0.tar.gz
(13.2 kB
view hashes)
Built Distribution
Close
Hashes for cdk_time_bomb-1.50.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e887f8e1a2e5be3249ff6c5fc322157cc51b70e95a82368ed555c6da13ff87e0 |
|
MD5 | b53373f7e3c655dd25bc1799646e9f86 |
|
BLAKE2b-256 | 29d3a47c03e1e68ebe893aff77b9c249736480af0390d96da0acaa8e669467e6 |