File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed
Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
88
99## [ Unreleased]
1010
11+ ### Fixed
12+
13+ - Fix reoncile issues related to handling the insecure flag in the OpenStack provider configuration.
14+
1115## [ 0.7.1] - 2025-06-18
1216
1317### Fixed
Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ func TerraformSetupBuilder(tfProvider *schema.Provider) terraform.SetupFn { //no
7171 "delayed_auth" , "allow_reauth" , "max_retries" , "enable_logging" }
7272
7373 ps .Configuration = map [string ]any {}
74+ // Provide default values for specific fields. They are the same as in the upstream provider.
7475 ps .Configuration ["insecure" ] = "false"
7576
7677 // ensures only the provided fields are set in the config
@@ -84,8 +85,12 @@ func TerraformSetupBuilder(tfProvider *schema.Provider) terraform.SetupFn { //no
8485}
8586
8687func configureNoForkOpenstackClient (ctx context.Context , ps * terraform.Setup , p schema.Provider ) error {
88+ // Populate the config, as well as the raw config for compatibility.
8789 config := tfsdk .NewResourceConfigRaw (ps .Configuration )
8890
91+ // The insecure flag is checked using getOkExists, which uses the CtyType instead of config/rawconfig.
92+ // See https://github.com/terraform-provider-openstack/terraform-provider-openstack/blob/v3.0.0/openstack/provider.go#L577
93+ // To ensure compatibility with the upstream provider, we need to set the insecure flag in the cty.Value format.
8994 insecure , err := strconv .ParseBool (ps .Configuration ["insecure" ].(string ))
9095 if err != nil {
9196 return errors .Wrap (err , "failed to parse 'insecure' configuration" )
You can’t perform that action at this time.
0 commit comments