Skip to content
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

How does terraform handle booleans? #342

Open
osterman opened this issue Dec 22, 2018 · 0 comments
Open

How does terraform handle booleans? #342

osterman opened this issue Dec 22, 2018 · 0 comments

Comments

@osterman
Copy link
Member

osterman commented Dec 22, 2018

What

  • Document why in terraform booleans should be expressed as type string rather than type boolean.

Why

  • The boolean default value true does not work consistently as expected and will in some cases be converted to false.

  • Terraform recommends using explicit strings instead of boolean values

Although it appears Terraform supports boolean types, they are instead silently converted to string types. The implications of this are subtle and should be completely understood if you plan on using boolean values. It is instead recommended you avoid using boolean values for now and use explicit strings. A future version of Terraform will properly support booleans and using the current behavior could result in backward-incompatibilities in the future.

References

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant