Skip to content

Commit

Permalink
Merge pull request #9038 from shiftstack/avoid-ipv4-rules
Browse files Browse the repository at this point in the history
OSASINFRA-3614: OpenStack: remove creation of IPv4 rules on Single stack IPv6 cluster
  • Loading branch information
openshift-merge-bot[bot] authored Sep 19, 2024
2 parents c72978e + 67d8d77 commit 0791483
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion pkg/infrastructure/openstack/preprovision/securitygroups.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,14 @@ func SecurityGroups(ctx context.Context, installConfig *installconfig.InstallCon

// In this loop: security groups with a catch-all remote IP
for ipVersion, anyIP := range map[rules.RuleEtherType][]string{
rules.EtherType4: {"0.0.0.0/0"},
rules.EtherType4: func() []string {
switch len(machineV4CIDRs) {
case 0:
return []string{}
default:
return []string{"0.0.0.0/0"}
}
}(),
rules.EtherType6: func() []string {
switch len(machineV6CIDRs) {
case 0:
Expand Down

0 comments on commit 0791483

Please sign in to comment.