Skip to content

Commit 5284c94

Browse files
anvitha-jainlhercot
authored andcommitted
Made changed to resource_aci_vmmctrlrp.go file to allow execution of terraform apply consecutively without error
1 parent c9c4b33 commit 5284c94

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

aci/resource_aci_vmmctrlrp.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ func getRemoteVMMController(client *client.Client, dn string) (*models.VMMContro
272272
vmmCtrlrP := models.VMMControllerFromContainer(vmmCtrlrPCont)
273273

274274
if vmmCtrlrP.DistinguishedName == "" {
275-
return nil, fmt.Errorf("Bridge Domain %s not found", vmmCtrlrP.DistinguishedName)
275+
return nil, fmt.Errorf("VMM Controller %s not found", vmmCtrlrP.DistinguishedName)
276276
}
277277

278278
return vmmCtrlrP, nil
@@ -284,7 +284,7 @@ func setVMMControllerAttributes(vmmCtrlrP *models.VMMController, d *schema.Resou
284284
// d.Set("vmm_domain_dn", GetParentDn(vmmCtrlrP.DistinguishedName))
285285
vmmCtrlrPMap, _ := vmmCtrlrP.ToMap()
286286
d.Set("name", vmmCtrlrPMap["name"])
287-
d.Set("vmm_domain_dn", GetParentDn(vmmCtrlrP.DistinguishedName, vmmCtrlrPMap["name"]))
287+
d.Set("vmm_domain_dn", GetParentDn(vmmCtrlrP.DistinguishedName, fmt.Sprintf("/ctrlr-%s", vmmCtrlrPMap["name"])))
288288

289289
d.Set("annotation", vmmCtrlrPMap["annotation"])
290290
d.Set("dvs_version", vmmCtrlrPMap["dvsVersion"])

examples/aci_vmm_domain/variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ variable "vmm_domain" {
77
}
88

99
variable "aci_vmm_controller" {
10-
default = "vmm-ctrl"
10+
default = "vmm_ctrl"
1111
}
1212

1313
variable "aci_vmm_credential" {

0 commit comments

Comments
 (0)