Terrasafe
https://github.com/PrismeaOpsTeam/Terrasafe
Terrasafe provide a way to secure your automated terraform pipeline and fail if an unauthorized deletion is planned.
Usage
terraform plan -out=tfplan
terraform show -json tfplan | terrasafe --config terrasafe.json
terraform apply --auto-approve tfplan
Configuration
The --config option allows to specify the path of the JSON configuration file.
{
"ignore_deletion": [ "aws_ecs_task_definition*" ], // Resource can be deleted
"ignore_deletion_if_recreation": [ "aws_ecs_task_definition*"], // Resource can be replaced
"unauthorized_deletion": [ "aws_ecs_task_definition*" ] // Resource can't be deleted by any way
}
How to delete a resource ?
- Comment it
- Or rename the file with the extension
.tf.disabled - Or define the Env var
TERRASAFE_ALLOW_DELETIONto the addresses of resources to delete, separated by;. Example:export TERRASAFE_ALLOW_DELETION=aws_ecs_task_definition.a;aws_lambda.b
Metadata
Release files for terrasafe 0.5.1
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 | |
|---|---|---|---|---|
| terrasafe-0.5.1.tar.gz | 4.0 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| terrasafe-0.5.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 7.7 kB
Release files / terrasafe-0.5.1.tar.gz
| Download URL | terrasafe-0.5.1.tar.gz |
|---|---|
| Size | 4.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4d1a2a9899a6dfaed6d1b909af4e3ae82f943e1b96f55211c7c6ee81721e2fd7
|
|
BLAKE2b-256 checksum How to use checksums |
372d232bf08f23785b7c2fb6bdba67c0707b5fee1231fd3c6563397a97818ab1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12
|
Release files / terrasafe-0.5.1-py3-none-any.whl
| Download URL | terrasafe-0.5.1-py3-none-any.whl |
|---|---|
| Size | 3.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1fa5eeb53d6019183f95251f73cde68161aadcf69204138a047615690453419f
|
|
BLAKE2b-256 checksum How to use checksums |
6ed80f8e8925238059727dda1d105bbf3419a4fee299a1d765e897eb19fada22
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12
|
Security for terrasafe 0.5.1
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.