rootsami / terradrift Goto Github PK
View Code? Open in Web Editor NEWA tool to detect drifts in terraform IaC
License: MIT License
A tool to detect drifts in terraform IaC
License: MIT License
I could be missing something but it appears from the examples that there is no S3 backend support. Is that the case?
I feel it's a common use case and would be a great addition here.
There is really not any competition in this area besides driftctl
and it's a fantastic area to improve on Terraform.
Seem like it could look for an atlantis.yaml in the git repo's root folder and build a stack config from that if it found it.
I think the variable REPOISTORY
should be REPOSITORY
. ๐
Current drift calculations are happening based on the human-readable plan output.
Plan: 0 to add, 0 to change, 4 to destroy.
It needs to be calculated in a programmatical way using terraform show -json <PLAN FILE>
to avoid any possible changes in the future versions of terraform
References: https://developer.hashicorp.com/terraform/internals/json-format#plan-representation
Getting the following error when I run terradrift-cli
OS: MacOS 13.2 - M1
terraform path:
which terraform
/opt/homebrew/bin/terraform
terradrift-cli --workdir="./stacks"
ERRO[0000] running NewTerraform: no suitable terraform binary could be found: NewTerraform: please supply the path to a Terraform executable using execPath, e.g. using the github.com/hashicorp/hc-install module.
if a stack drift scan fails to run for any reason, it fails silently and only reports in the logs
Add metrics for stack failure to be able to monitor failures.
Type: gauge
Unit: bool
Description: Has a value of 1 when failure is detected, and 0 when it's not.
Example:
# HELP terradrift_plan_failure Status of the latest scan run
# TYPE terradrift_plan_failure gauge
terradrift_plan_failure{stack="api-staging"} 0
Currently if terraform version is not defined in tf files, it throws an error.
ERRO[0000] no problems stack=gcp-core-staging
ERRO[0000] running NewTerraform: no suitable terraform binary could be found: NewTerraform: please supply the path to a Terraform executable using execPath, e.g. using the github.com/hashicorp/hc-install module. stack=gcp-core-staging
How to reproduce it:
remove the block and run terradrift against the example stacks
Possible Actions:
terraform init
with a later tf versionA declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.