terraform-provider-fortios icon indicating copy to clipboard operation
terraform-provider-fortios copied to clipboard

Changing existing reserved_address on fortios_systemdhcp_server

Open MrMinos opened this issue 3 years ago • 1 comments

I've ran into a problem where I cannot delete a reserved_address element and shift the id over by one. terraform apply fails with a 500 error.

Say I'm deleting "Some B", and all the reserved_address shifts over by one as below example plan output, the provider fails with status code 500. I believe this happens because when you are modifying the reserved_address of "Some B" to "Some C", at one point you will two "Some C"s. Is there a way to get around this?

Thank you!

    reserved_address {
        description     = "Some B" -> "Some C"
        id              = 15
        ip              = "10.20.30.40" -> "10.20.30.50"
        mac             = "aa:aa:aa:aa:aa:aa" -> "bb:bb:bb:bb:bb:bb"
    }
    reserved_address {
        description     = "Some C" -> "Some D"
        id              = 16
        ip              = "10.20.30.50" -> "10.20.30.60"
        mac             = "bb:bb:bb:bb:bb:bb" -> "cc:cc:cc:cc:cc:cc"
    }
    reserved_address {
        description     = "Some D" -> "Some E"
        id              = 17
        ip              = "10.20.30.60" -> "10.20.30.70"
        mac             = "cc:cc:cc:cc:cc:cc" -> "dd:dd:dd:dd:dd:dd"
    }

MrMinos avatar Jan 28 '22 06:01 MrMinos

Hi @MrMinos,

Thank you for raising this issue. This issue is caused by the Terraform comparison of list of block object. Team are working on this kind of issue. We will get back to you once it's resolved.

Thanks, Xing

lix-fortinet avatar Feb 09 '22 19:02 lix-fortinet