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

[v1.13] Bump envoy to v1.27.x #31498

Merged
merged 10 commits into from
Apr 2, 2024
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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
10 changes: 10 additions & 0 deletions Documentation/network/servicemesh/l7-traffic-management.rst
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,21 @@ Only the extensions that have not been commented out with ``#`` are
built in to the Cilium Envoy image. Currently this contains the
following extensions:

- ``envoy.access_loggers.file``
- ``envoy.access_loggers.extension_filters.cel``
- ``envoy.access_loggers.http_grpc``
- ``envoy.access_loggers.tcp_grpc``
- ``envoy.access_loggers.open_telemetry``
- ``envoy.access_loggers.stdout``
- ``envoy.access_loggers.stderr``
- ``envoy.access_loggers.wasm``
- ``envoy.clusters.dynamic_forward_proxy``
- ``envoy.filters.http.dynamic_forward_proxy``
- ``envoy.filters.http.ext_authz``
- ``envoy.filters.http.jwt_authn``
- ``envoy.filters.http.local_ratelimit``
- ``envoy.filters.http.grpc_stats``
- ``envoy.filters.http.grpc_web``
- ``envoy.filters.http.oauth2``
- ``envoy.filters.http.ratelimit``
- ``envoy.filters.http.router``
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ debug: all

include Makefile.defs

SUBDIRS_CILIUM_CONTAINER := proxylib envoy bpf cilium daemon cilium-health bugtool tools/mount tools/sysctlfix
SUBDIRS_CILIUM_CONTAINER := envoy bpf cilium daemon cilium-health bugtool tools/mount tools/sysctlfix
SUBDIRS := $(SUBDIRS_CILIUM_CONTAINER) operator plugins tools hubble-relay

SUBDIRS_CILIUM_CONTAINER += plugins/cilium-cni
Expand Down
19 changes: 19 additions & 0 deletions daemon/cmd/daemon_main.go
Original file line number Diff line number Diff line change
Expand Up @@ -1781,6 +1781,25 @@ func runDaemon(d *Daemon, restoredEndpoints *endpointRestoreState, cleaner *daem
}
}

if option.Config.EnableEnvoyConfig {
if !d.endpointManager.IngressEndpointExists() {
// Creating Ingress Endpoint depends on the Ingress IPs having been
// allocated first. This happens earlier in the agent bootstrap.
if (option.Config.EnableIPv4 && len(node.GetIngressIPv4()) == 0) ||
(option.Config.EnableIPv6 && len(node.GetIngressIPv6()) == 0) {
log.Warn("Ingress IPs are not available, skipping creation of the Ingress Endpoint: Policy enforcement on Cilium Ingress will not work as expected.")
} else {
log.Info("Creating ingress endpoint")
if err := d.endpointManager.AddIngressEndpoint(
d.ctx, d, d, d.ipcache, d.l7Proxy, d.identityAllocator,
"Create ingress endpoint",
); err != nil {
log.Fatalf("unable to create ingress endpoint: %s", err)
}
}
}
}

if option.Config.EnableIPMasqAgent {
ipmasqAgent, err := ipmasq.NewIPMasqAgent(option.Config.IPMasqAgentConfigPath)
if err != nil {
Expand Down
20 changes: 10 additions & 10 deletions daemon/cmd/policy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -347,12 +347,12 @@ func (ds *DaemonSuite) TestUpdateConsumerMap(c *C) {

qaBarNetworkPolicy := networkPolicies[QAIPv4Addr.String()]
c.Assert(qaBarNetworkPolicy, Not(IsNil))
expectedRemotePolicies := []uint64{
uint64(qaFooSecLblsCtx.ID),
expectedRemotePolicies := []uint32{
uint32(qaFooSecLblsCtx.ID),
// The prodFoo* identities are allowed by FromEndpoints but rejected by
// FromRequires, so they are not included in the remote policies:
// uint64(prodFooSecLblsCtx.ID),
// uint64(prodFooJoeSecLblsCtx.ID),
// uint32(prodFooSecLblsCtx.ID),
// uint32(prodFooJoeSecLblsCtx.ID),
}
sort.Slice(expectedRemotePolicies, func(i, j int) bool {
return expectedRemotePolicies[i] < expectedRemotePolicies[j]
Expand Down Expand Up @@ -389,12 +389,12 @@ func (ds *DaemonSuite) TestUpdateConsumerMap(c *C) {

prodBarNetworkPolicy := networkPolicies[ProdIPv4Addr.String()]
c.Assert(prodBarNetworkPolicy, Not(IsNil))
expectedRemotePolicies = []uint64{
expectedRemotePolicies = []uint32{
// The qaFoo identity is allowed by FromEndpoints but rejected by
// FromRequires, so it is not included in the remote policies:
// uint64(qaFooSecLblsCtx.ID),
uint64(prodFooSecLblsCtx.ID),
uint64(prodFooJoeSecLblsCtx.ID),
uint32(prodFooSecLblsCtx.ID),
uint32(prodFooJoeSecLblsCtx.ID),
}
sort.Slice(expectedRemotePolicies, func(i, j int) bool {
return expectedRemotePolicies[i] < expectedRemotePolicies[j]
Expand Down Expand Up @@ -499,7 +499,7 @@ func (ds *DaemonSuite) TestL4_L7_Shadowing(c *C) {
Rules: []*cilium.PortNetworkPolicyRule{
{},
{
RemotePolicies: []uint64{uint64(qaFooSecLblsCtx.ID)},
RemotePolicies: []uint32{uint32(qaFooSecLblsCtx.ID)},
L7: &PNPAllowGETbarLog,
},
},
Expand Down Expand Up @@ -670,7 +670,7 @@ func (ds *DaemonSuite) TestL3_dependent_L7(c *C) {
Protocol: envoy_config_core.SocketAddress_TCP,
Rules: []*cilium.PortNetworkPolicyRule{
{
RemotePolicies: []uint64{uint64(qaJoeSecLblsCtx.ID)},
RemotePolicies: []uint32{uint32(qaJoeSecLblsCtx.ID)},
},
},
},
Expand Down Expand Up @@ -962,7 +962,7 @@ func (ds *DaemonSuite) TestIncrementalPolicy(c *C) {
Protocol: envoy_config_core.SocketAddress_TCP,
Rules: []*cilium.PortNetworkPolicyRule{
{
RemotePolicies: []uint64{uint64(qaFooID.ID)},
RemotePolicies: []uint32{uint32(qaFooID.ID)},
},
},
},
Expand Down
31 changes: 16 additions & 15 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,9 @@ require (
github.com/cilium/dns v1.1.51-0.20231120140355-729345173dc3
github.com/cilium/ebpf v0.9.4-0.20221102092914-a9cf21df64c2
github.com/cilium/ipam v0.0.0-20220824141044-46ef3d556735
github.com/cilium/kafka v0.0.0-20180809090225-01ce283b732b
github.com/cilium/lumberjack/v2 v2.2.2
github.com/cilium/proxy v0.0.0-20230709104538-6aa1c739866f
github.com/cilium/proxy v0.0.0-20230911173141-49b6a7c9c075
github.com/cilium/workerpool v1.1.3
github.com/containernetworking/cni v1.1.2
github.com/containernetworking/plugins v1.1.1
Expand All @@ -48,7 +49,7 @@ require (
github.com/google/gopacket v1.1.19
github.com/google/gops v0.3.26
github.com/google/renameio v1.0.1
github.com/google/uuid v1.3.0
github.com/google/uuid v1.3.1
github.com/gorilla/mux v1.8.0
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0
github.com/hashicorp/consul/api v1.18.0
Expand All @@ -62,11 +63,10 @@ require (
github.com/mitchellh/mapstructure v1.5.0
github.com/onsi/ginkgo v1.16.5
github.com/onsi/gomega v1.24.1
github.com/optiopay/kafka v0.0.0-00010101000000-000000000000
github.com/osrg/gobgp/v3 v3.5.0
github.com/pmezard/go-difflib v1.0.0
github.com/prometheus/client_golang v1.14.0
github.com/prometheus/client_model v0.3.0
github.com/prometheus/client_model v0.4.0
github.com/prometheus/procfs v0.8.0
github.com/russross/blackfriday/v2 v2.1.0
github.com/sasha-s/go-deadlock v0.3.1
Expand All @@ -77,7 +77,7 @@ require (
github.com/spf13/cobra v1.6.1
github.com/spf13/pflag v1.0.5
github.com/spf13/viper v1.14.0
github.com/stretchr/testify v1.8.1
github.com/stretchr/testify v1.8.2
github.com/tidwall/gjson v1.14.4
github.com/tidwall/sjson v1.2.5
github.com/vishvananda/netlink v1.2.1-beta.2.0.20220608195807-1a118fe229fc
Expand All @@ -93,17 +93,17 @@ require (
go.universe.tf/metallb v0.11.0
golang.org/x/crypto v0.17.0
golang.org/x/exp v0.0.0-20221106115401-f9659909a136
golang.org/x/mod v0.10.0
golang.org/x/mod v0.11.0
golang.org/x/net v0.17.0
golang.org/x/sync v0.1.0
golang.org/x/sync v0.2.0
golang.org/x/sys v0.15.0
golang.org/x/term v0.15.0
golang.org/x/time v0.2.0
golang.org/x/tools v0.7.0
golang.org/x/tools v0.8.0
golang.zx2c4.com/wireguard v0.0.0-20211017052713-f87e87af0d9a
golang.zx2c4.com/wireguard/wgctrl v0.0.0-20211027115401-c9b1ec1aa6d8
google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1
google.golang.org/grpc v1.56.3
google.golang.org/genproto/googleapis/rpc v0.0.0-20230803162519-f966b187b2e5
google.golang.org/grpc v1.57.0
google.golang.org/protobuf v1.33.0
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c
gopkg.in/ini.v1 v1.67.0
Expand All @@ -113,7 +113,7 @@ require (
k8s.io/apimachinery v0.26.9
k8s.io/client-go v0.26.9
k8s.io/code-generator v0.26.9
k8s.io/klog/v2 v2.80.1
k8s.io/klog/v2 v2.100.1
k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280
k8s.io/utils v0.0.0-20221107191617-1a15be271d1d
sigs.k8s.io/controller-runtime v0.13.1-0.20221201045826-d9912251cd81
Expand Down Expand Up @@ -156,7 +156,7 @@ require (
github.com/eapache/channels v1.1.0 // indirect
github.com/eapache/queue v1.1.0 // indirect
github.com/emicklei/go-restful/v3 v3.10.2 // indirect
github.com/envoyproxy/protoc-gen-validate v0.10.1 // indirect
github.com/envoyproxy/protoc-gen-validate v1.0.1 // indirect
github.com/evanphx/json-patch/v5 v5.6.0 // indirect
github.com/fatih/color v1.13.0 // indirect
github.com/go-kit/kit v0.12.0 // indirect
Expand Down Expand Up @@ -230,12 +230,15 @@ require (
github.com/yusufpapurcu/wmi v1.2.2 // indirect
gitlab.com/golang-commonmark/puny v0.0.0-20191124015043-9f83538fa04f // indirect
go.mongodb.org/mongo-driver v1.10.0 // indirect
go.opentelemetry.io/proto/otlp v1.0.0 // indirect
go.uber.org/atomic v1.9.0 // indirect
go.uber.org/zap v1.23.0 // indirect
golang.org/x/oauth2 v0.7.0 // indirect
golang.org/x/oauth2 v0.11.0 // indirect
golang.org/x/text v0.14.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20230803162519-f966b187b2e5 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20230803162519-f966b187b2e5 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
Expand All @@ -247,8 +250,6 @@ require (
)

replace (
github.com/optiopay/kafka => github.com/cilium/kafka v0.0.0-20180809090225-01ce283b732b

go.universe.tf/metallb => github.com/cilium/metallb v0.1.1-0.20220829170633-5d7dfb1129f7

// Using fork of client-go.
Expand Down