Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions calico-vpp-agent/felix/host_endpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,13 @@ func (h *HostEndpoint) getTapPolicies(state *PolicyState) (conf *types.Interface
if err != nil {
return nil, errors.Wrap(err, "cannot create host policies for TapConf")
}
if len(conf.IngressPolicyIDs) > 0 {
conf.IngressPolicyIDs = append(conf.IngressPolicyIDs, h.server.workloadsToHostPolicy.VppID)
if len(conf.IngressPolicyIDs) > 0 || len(conf.ProfileIDs) == 0 {
conf.IngressPolicyIDs = append([]uint32{h.server.failSafePolicy.VppID}, conf.IngressPolicyIDs...)
conf.IngressPolicyIDs = append([]uint32{h.server.workloadsToHostPolicy.VppID}, conf.IngressPolicyIDs...)
}
if len(conf.EgressPolicyIDs) > 0 {
conf.EgressPolicyIDs = append([]uint32{h.server.AllowFromHostPolicy.VppID}, conf.EgressPolicyIDs...)
if len(conf.EgressPolicyIDs) > 0 || len(conf.ProfileIDs) == 0 {
conf.EgressPolicyIDs = append([]uint32{h.server.failSafePolicy.VppID}, conf.EgressPolicyIDs...)
conf.EgressPolicyIDs = append([]uint32{h.server.AllowFromHostPolicy.VppID}, conf.EgressPolicyIDs...)
}
return conf, nil
}
Expand Down
Loading