mirror of
https://github.com/opentofu/opentofu.git
synced 2024-12-28 01:41:48 -06:00
966eb39427
Prior to Terraform v0.12 it was possible for a provider to secretly set some default arguments for the "connection" block, which most commonly included a hard-coded type of "ssh" and a value from "host". In the interests of "explicit is better than implicit", Terraform 0.12 no longer has this feature and instead requires connection settings to be written explicitly in terms of the resource's exported attributes. For compatibility though, the upgrade tool will insert expressions that are as close as possible to the logic the provider formerly implemented, or in a few rare cases a TF-UPGRADE-TODO comment to fix it up manually. Some of the existing resource type implementations have incredibly complicated implementations of selecting a single host IP address to use and don't expose the result of that as an attribute, so for now we handle those via a complicated Terraform language expression achieving the same result. Ideally these providers would introduce a new attribute that exports the same address formerly exported as the hostname before their initial v0.12-compatible release, in which case we can simplify these to just reference the attribute in question. That would be preferable also because it would allow use of that exported attribute in other contexts, such as in a null_resource provisioner somewhere else or in an output to allow a caller to deal with the SSH part itself. |
||
---|---|---|
.. | ||
configload | ||
configschema | ||
configupgrade | ||
test-fixtures | ||
backend.go | ||
compat_shim.go | ||
config_build_test.go | ||
config_build.go | ||
config_test.go | ||
config.go | ||
depends_on.go | ||
doc.go | ||
module_call_test.go | ||
module_call.go | ||
module_merge_body.go | ||
module_merge_test.go | ||
module_merge.go | ||
module.go | ||
named_values.go | ||
parser_config_dir_test.go | ||
parser_config_dir.go | ||
parser_config_test.go | ||
parser_config.go | ||
parser_test.go | ||
parser_values_test.go | ||
parser_values.go | ||
parser.go | ||
provider_test.go | ||
provider.go | ||
provisioner.go | ||
provisioneronfailure_string.go | ||
provisionerwhen_string.go | ||
resource.go | ||
synth_body_test.go | ||
synth_body.go | ||
util.go | ||
variable_type_hint.go | ||
variabletypehint_string.go | ||
version_constraint.go |