-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Specify all variables as non-nullable
#221
Specify all variables as non-nullable
#221
Conversation
This means that we need not worry about whether variables are explicitly specified as null. Since this is not something we were expecting, it makes sense to avoid the situation. See also: https://developer.hashicorp.com/terraform/language/values/variables#disallowing-null-input-values
The |
No concerns here. We are using version 1.5.7 in our GH Actions workflows. |
Version 1.1 of Terraform is the first version to support the nullable key in variable definitions. Also update the comment associated with this line to something a bit more truthful, since we are using 1.5.7 in cisagov/setup-env-github-action. Co-authored-by: David Redmin <[email protected]>
43ef99c
to
c551420
Compare
See commit c551420. |
Hi Shane @jsf9k, the Readme file still shows the reference to terraform ~> 1.0 |
Hi Shane @jsf9k, under directory examples/basic_usage: same for Readme file and version.tf there reference to terraform ~> 1.0 |
f9bf064
to
139eefd
Compare
Co-authored-by: David Harris <[email protected]>
Co-authored-by: David Harris <[email protected]>
139eefd
to
193083a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems reasonable enough.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
In #221 we made all of the variables in the example module non-nullable but did not do the same to the `basic_usage` example. Since it uses variables beyond the requirements of the example module it makes sense to also specify the example's variables as non-nullable.
🗣 Description
This pull request specifies all variables as non-
nullable
.💭 Motivation and context
This means that we need not worry about whether variables are explicitly specified as
null
. Since this is not something we were expecting, it makes sense to avoid the situation.See also the Terraform documentation.
🧪 Testing
All automated tests pass.
✅ Pre-approval checklist