logicmonitor/terraform-provider-logicmonitor

logicmonitor_collector predefined_config not importing

gdiersing opened this issue · 1 comments

I'm using the command terraform import logicmonitor_collector.my_collector <ID> to import existing collectors. After updating the code to reflect the imported resource, I run terraform plan which shows pending updates on the collectors stating:

+ predefined_config = (known after apply)

I run terraform apply and accept the pending change, which confirms Apply complete! Resources: 0 added, 2 changed, 0 destroyed.

However, when I run terraform plan again expecting nothing I get the same pending update for predefined_config

I'm running into this issue as well - Now every time i run a plan/apply, there's a difference:

  # logicmonitor_collector.test will be updated in-place
  ~ resource "logicmonitor_collector" "test" {
        id                                   = "28"
      + predefined_config                    = (known after apply)
        # (61 unchanged attributes hidden)
    }

Even with no other changes, every time I run an apply in my terraform environment there's an entry in the audit log Update Collector 28 (test) via API token XXXXXX

I tried to ignore but since it's determined by the provider alone it cannot be ignored:

│ Warning: Redundant ignore_changes element
│
│   on main.tf line 44, in resource "logicmonitor_collector" "test":
│   44: resource "logicmonitor_collector" "test" {
│
│ Adding an attribute name to ignore_changes tells Terraform to ignore future changes to the argument in configuration after the object
│ has been created, retaining the value originally configured.
│
│ The attribute predefined_config is decided by the provider alone and therefore there can be no configured value to compare with.
│ Including this attribute in ignore_changes has no effect. Remove the attribute from ignore_changes to quiet this warning.
╵

Please help get this fixed. Unless there's a valid change, we should not be seeing any changes.