Skip to content

Commit

Permalink
Merge pull request #15347 from justinsb/gce_icmpv6
Browse files Browse the repository at this point in the history
gce: fix icmpv6 in firewalls
  • Loading branch information
k8s-ci-robot committed Apr 26, 2023
2 parents b6fe79a + b835184 commit 2875f70
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions pkg/model/gcemodel/firewall.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,5 +198,14 @@ func (b *GCEModelContext) AddFirewallRulesTasks(c *fi.CloudupModelBuilderContext
ipv6.Disabled = true
ipv6.SourceRanges = []string{"::/0"}
}
var ipv6Allowed []string
for _, allowed := range ipv6.Allowed {
// Map icmp to icmpv6; easier than maintaining separate lists
if allowed == "icmp" {
allowed = "58" // 58 == the IANA protocol number for ICMPv6
}
ipv6Allowed = append(ipv6Allowed, allowed)
}
ipv6.Allowed = ipv6Allowed
c.AddTask(&ipv6)
}

0 comments on commit 2875f70

Please sign in to comment.