-
Notifications
You must be signed in to change notification settings - Fork 545
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
cloudflare_access_identity_provider
does not import config block settings
#1419
Comments
FWIW, if I make the following change and test that, the import works as expected. I'm unclear of the history or why it looks for that to begin with, so figured I'd leave it up to you to figure out the best way forward. diff --git a/cloudflare/resource_cloudflare_access_identity_provider.go b/cloudflare/resource_cloudflare_access_identity_provider.go
index ca838496..e5fe0f0b 100644
--- a/cloudflare/resource_cloudflare_access_identity_provider.go
+++ b/cloudflare/resource_cloudflare_access_identity_provider.go
@@ -212,10 +212,6 @@ func convertSchemaToStruct(d *schema.ResourceData) (cloudflare.AccessIdentityPro
}
func convertStructToSchema(d *schema.ResourceData, options cloudflare.AccessIdentityProviderConfiguration) []interface{} {
- if _, ok := d.GetOk("config"); !ok {
- return []interface{}{}
- }
-
attributes := make([]string, 0)
for _, value := range options.Attributes {
attributes = append(attributes, value) |
The problem has still not been resolved, although PR is attached. Is there any chance that case will be resolved? |
I was searching through open issues before I opened a new one regarding this same topic. I can confirm on v3.26.0 this is still an issue. I think it's due to the fact that the provider is confusing types here, since If you'd like to fix this temporarily, you can edit your tfstate file directly and add your config attributes inside the
This will result in zero changes being planned. |
The problem has still not been resolved |
Confirmation
Terraform and Cloudflare provider version
terraform -v
Terraform v1.1.4
on linux_amd64
Affected resource(s)
Terraform configuration files
Debug output
Notice how the result from the API call includes a
config {}
block. I would expect this to get imported.Panic output
No response
Expected output
I expected the existing saml
config {}
block to be imported into the state file.Actual output
The
config {}
block of settings was not imported.Steps to reproduce
import any identity providers with a config block.
Additional factoids
No response
References
No response
The text was updated successfully, but these errors were encountered: