This repository was archived by the owner on Jun 29, 2022. It is now read-only.
Add diff flag to terraform check - #1332
Open
Imran Pochi (ipochi) wants to merge 2 commits into
Open
Imran Pochi (ipochi) wants to merge 2 commits into
Imran Pochi (ipochi) wants to merge 2 commits into
Conversation
added 2 commits
January 19, 2021 19:26
This commit adds a `-diff` flag to `terraform fmt`, so that the user can see the output what needs to be fixed. Signed-off-by: Imran Pochi <imran@kinvolk.io>
This commit addresses the files that need to be properly formatted after running `make check-terraform` Signed-off-by: Imran Pochi <imran@kinvolk.io>
| node_labels = merge({ | ||
| "node.kubernetes.io/node" = "", | ||
| "lokomotive.alpha.kinvolk.io/bgp-enabled" = format("%t", !var.disable_bgp), | ||
| "lokomotive.alpha.kinvolk.io/bgp-enabled" = format("%t", ! var.disable_bgp), |
There was a problem hiding this comment.
What version of Terraform you use? For me, 0.14.x allows !var.x formatting.
Member
Author
There was a problem hiding this comment.
terraform version
Terraform v0.13.4
We support 0.13 , so thats what the linter should also use.
There was a problem hiding this comment.
It seems GitHub Action agrees with me 馃槃
Member
Author
There was a problem hiding this comment.
I believe the terraform fmt should be based on 0.13. Github Actions needs to change.
What do you think ?
There was a problem hiding this comment.
Not sure how to proceed here 馃
There was a problem hiding this comment.
I'm not even sure why GitHub Action has Terraform already installed actually 馃槃 But yeah, we can change GitHub action to have 0.13.x then.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds the adds a
-diffflag toterraform fmt, so that the user can see the output what needs to be fixed.