Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

daemon: Fatal on BPF masquerade + IPv6 masquerade #17906

Merged
merged 1 commit into from
Nov 22, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions daemon/cmd/daemon_main.go
Original file line number Diff line number Diff line change
Expand Up @@ -1411,6 +1411,10 @@ func initEnv(cmd *cobra.Command) {
option.Config.EnableBandwidthManager = false
}

if option.Config.EnableIPv6Masquerade && option.Config.EnableBPFMasquerade {
log.Fatal("BPF masquerade is not supported for IPv6.")
}

// If there is one device specified, use it to derive better default
// allocation prefixes
node.InitDefaultPrefix(option.Config.DirectRoutingDevice)
Expand Down
1 change: 1 addition & 0 deletions test/helpers/kubectl.go
Original file line number Diff line number Diff line change
Expand Up @@ -2370,6 +2370,7 @@ func (kub *Kubectl) overwriteHelmOptions(options map[string]string) error {

if RunsOn419OrLaterKernel() {
opts["bpf.masquerade"] = "true"
opts["enableIPv6Masquerade"] = "false"
}

for key, value := range opts {
Expand Down