Skip to content

Commit aee8a6c

Browse files
akinrosslhercot
authored andcommitted
[bugfix] Fix to allow updating of attributes in the aci_external_network_instance_profile resource
1 parent d4b5d20 commit aee8a6c

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

aci/resource_aci_l3extinstp.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -642,6 +642,11 @@ func resourceAciExternalNetworkInstanceProfileUpdate(ctx context.Context, d *sch
642642
}
643643
l3extInstP := models.NewExternalNetworkInstanceProfile(fmt.Sprintf(models.Rnl3extinstp, name), L3OutsideDn, desc, l3extInstPAttr)
644644

645+
// Workaround for the issue with the client where status is set to "created, modified"
646+
// This cause an error 103 {"imdata":[{"error":{"attributes":{"code":"103","text":"Cannot create External Network Instance Profile (l3extInstP); object uni/tn-terraform_tenant/out-l3_outside/instP-external_epg_1 already exists."}}}],"totalCount":"1"}
647+
// Changing the status to "modified" to avoid this error
648+
l3extInstP.BaseAttributes.Status = "modified"
649+
645650
err := aciClient.Save(l3extInstP)
646651

647652
if err != nil {

0 commit comments

Comments
 (0)