https://github.com/sceptre/sceptre-stack-termination-protection-hook
A Sceptre hook to enable and disable stack termination protection
https://github.com/sceptre/sceptre-stack-termination-protection-hook
sceptre sceptre-hook
Last synced: about 1 month ago
JSON representation
A Sceptre hook to enable and disable stack termination protection
- Host: GitHub
- URL: https://github.com/sceptre/sceptre-stack-termination-protection-hook
- Owner: Sceptre
- Created: 2020-04-26T21:06:00.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-12-26T20:51:36.000Z (over 2 years ago)
- Last Synced: 2025-02-22T12:45:59.644Z (2 months ago)
- Topics: sceptre, sceptre-hook
- Language: Python
- Size: 11.7 KB
- Stars: 0
- Watchers: 8
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
# Overview
The purpose of this hook is to enable and disable
[stack termination protection](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-protect-stacks.html).A common use case is execute this hook with your CI/CD
system. In that case you may need to execute this on every
change. That's where the
[sceptre-date-resolver](https://github.com/sceptre/sceptre-date-resolver)
may help. It will allow you to force AWS cloudformation to execute the
template on on every commit.## Available Hooks
### StackTermination
Enables and disables cloudformation stack termination.
Syntax:
```yaml
parameter|sceptre_user_data:
: !stack_termination_protection
```
Valid setting:
* enabled
* disabledExample:
Enable stack termination protection after creating stack
and disable stack termination protection before stack deletion:
```
hooks:
after_create:
- !stack_termination_protection 'enabled'
before_delete:
- !stack_termination_protection 'disabled'
```