Skip SG ID determination logic for Classic ELBs
This commit is contained in:
parent
b7c41aed92
commit
5753efa8af
|
@ -350,12 +350,12 @@ func resourceAwsElbRead(d *schema.ResourceData, meta interface{}) error {
|
||||||
var elbVpc string
|
var elbVpc string
|
||||||
if lb.VPCId != nil {
|
if lb.VPCId != nil {
|
||||||
elbVpc = *lb.VPCId
|
elbVpc = *lb.VPCId
|
||||||
}
|
sgId, err := sourceSGIdByName(meta, *lb.SourceSecurityGroup.GroupName, elbVpc)
|
||||||
sgId, err := sourceSGIdByName(meta, *lb.SourceSecurityGroup.GroupName, elbVpc)
|
if err != nil {
|
||||||
if err != nil {
|
return fmt.Errorf("[WARN] Error looking up ELB Security Group ID: %s", err)
|
||||||
return fmt.Errorf("[WARN] Error looking up ELB Security Group ID: %s", err)
|
} else {
|
||||||
} else {
|
d.Set("source_security_group_id", sgId)
|
||||||
d.Set("source_security_group_id", sgId)
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
d.Set("subnets", lb.Subnets)
|
d.Set("subnets", lb.Subnets)
|
||||||
|
|
Loading…
Reference in New Issue