5c38456b05
In `helper/schema` we already makes a distinction between `Default` which is always applied and `InputDefault` which is displayed to the user for an empty field. But for variables we just have `Default` which is treated like `InputDefault`. This changes it to _not_ prompt the user for a value when the variable declaration includes a default. Treating this as a UX bugfix and the "don't prompt for variables w/ defaults set" behavior as the originally expected behavior we were failing to honor. Added an already-passing test to verify and cover the `helper/schema` behavior. Perhaps down the road we can add a `input_default` attribute to variables to allow similar behavior to `helper/schema` in variables, but for now just sticking with the fix. Fixes #2592 |
||
---|---|---|
.. | ||
README.md | ||
equal.go | ||
field_reader.go | ||
field_reader_config.go | ||
field_reader_config_test.go | ||
field_reader_diff.go | ||
field_reader_diff_test.go | ||
field_reader_map.go | ||
field_reader_map_test.go | ||
field_reader_multi.go | ||
field_reader_multi_test.go | ||
field_reader_test.go | ||
field_writer.go | ||
field_writer_map.go | ||
field_writer_map_test.go | ||
getsource_string.go | ||
provider.go | ||
provider_test.go | ||
resource.go | ||
resource_data.go | ||
resource_data_get_source.go | ||
resource_data_test.go | ||
resource_test.go | ||
schema.go | ||
schema_test.go | ||
set.go | ||
set_test.go | ||
valuetype.go | ||
valuetype_string.go |
README.md
Terraform Helper Lib: schema
The schema
package provides a high-level interface for writing resource
providers for Terraform.
If you're writing a resource provider, we recommend you use this package.
The interface exposed by this package is much friendlier than trying to write to the Terraform API directly. The core Terraform API is low-level and built for maximum flexibility and control, whereas this library is built as a framework around that to more easily write common providers.