mirror of https://github.com/kubernetes/kops.git
Fix for when node and master use the same SG.
This commit is contained in:
parent
6af981378c
commit
a7903adfe8
|
@ -81,8 +81,9 @@ func (b *AutoscalingGroupModelBuilder) Build(c *fi.ModelBuilderContext) error {
|
|||
if ig.Spec.SecurityGroupOverride != nil {
|
||||
glog.V(1).Infof("WARNING: You are overwriting the Instance Groups, Security Group. When this is done you are responsible for ensure the correct rules!")
|
||||
|
||||
sgName := fmt.Sprintf("%v-%v", fi.StringValue(ig.Spec.SecurityGroupOverride), ig.Spec.Role)
|
||||
sgLink = &awstasks.SecurityGroup{
|
||||
Name: ig.Spec.SecurityGroupOverride,
|
||||
Name: &sgName,
|
||||
ID: ig.Spec.SecurityGroupOverride,
|
||||
Shared: fi.Bool(true),
|
||||
}
|
||||
|
|
|
@ -483,8 +483,9 @@ func (b *KopsModelContext) GetSecurityGroups(role kops.InstanceGroupRole) ([]Sec
|
|||
}
|
||||
done[name] = true
|
||||
|
||||
sgName := fmt.Sprintf("%v-%v", fi.StringValue(ig.Spec.SecurityGroupOverride), role)
|
||||
t := &awstasks.SecurityGroup{
|
||||
Name: ig.Spec.SecurityGroupOverride,
|
||||
Name: &sgName,
|
||||
ID: ig.Spec.SecurityGroupOverride,
|
||||
VPC: b.LinkToVPC(),
|
||||
Shared: fi.Bool(true),
|
||||
|
|
Loading…
Reference in New Issue