spidernet-io / egressgateway Goto Github PK
View Code? Open in Web Editor NEWNetwork egress policy for Kubernetes
Home Page: https://spidernet-io.github.io/egressgateway/
License: Apache License 2.0
Network egress policy for Kubernetes
Home Page: https://spidernet-io.github.io/egressgateway/
License: Apache License 2.0
Describe the version
egressgateway v0.1.0
Describe the bug
after changing the mac address of egress.vxlan on the node, the mac address did not restore its original value based on the egressnode cr status.tunnelMac
Hwo To Reproduce
Steps to reproduce the issue:
Expected behavior
the mac address should restore its original value based on the egressnode cr status.tunnelMac
Describe the version
Describe the bug
Consider a pod(located in node A) backing a LoadBalancer service, and the pod is matched an egress rule: the packets of pod access to external forwarded via Node B.
Now I announced the loadBalancer IP to node A via metallb
L2 mode. In this case, the LB IP cannot be accessed by clients outside the cluster.
1.1.1.1
10.6.212.100
10.244.0.1
Node B
10.6.212.101
10.6.212.102
package flow:
request package: 1.1.1.1(client) -> 10.6.212.100(lb IP) -> Node A -> dnat -> 10.244.0.1
reply package: 10.244.0.1 -> match egressRule -> Node B -> ?(drop)
Hwo To Reproduce
Steps to reproduce the issue:
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots and log
If applicable, add screenshots and log to help explain your problem.
Additional context
Add any other context about the problem here.
Documentation issue
Work in default calico config.
In most use cases the chainInsertMode is set to the default value.
Would we improve the egress gateway to support calico chainInsertMode=Insert
Describe the version
egressgateway v0.1.0
Describe the bug
the status.physicalInterface of the egressnode cr have not been upgrade after i changed the node interface name
Hwo To Reproduce
Steps to reproduce the issue:
Expected behavior
we expect that the status.physicalInterface of the egressnode cr would be upgraded same with the node interface name
refer to: #217
1 verify datapath model with calico cilium macvlan
2 update datapath designe markdown
3 tcp udp websocket
When EgressGateway creation preceded node labeling, EgressGateway CR status not updated.
Bug reported by @bzsuni.
├── api
│ └── v1
├── charts
├── cmd
│ ├── agent
│ │ ├── cmd
│ │ │ └── root.go
│ │ └── main.go
│ └── controller
│ ├── cmd
│ │ └── root.go
│ └── main.go
├── docs
├── images
├── output
├── pkg
│ ├── config
│ │ └── config.go
│ ├── agent
│ │ ├── agent.go
│ │ ├── egress_gateway_node.go
│ │ ├── egress_node.go
│ │ ├── egress_police.go
│ │ ├── ipset
│ │ │ ├── ipset.go
│ │ │ └── types.go
│ │ ├── iptables
│ │ │ └── iptables.go
│ │ ├── route
│ │ │ └── route.go
│ │ └── vxlan
│ │ └── vxlan.go
│ ├── controller
│ │ ├── allocator
│ │ │ └── interface.go
│ │ ├── controller.go
│ │ ├── controller_test.go
│ │ ├── egress_gateway_node.go
│ │ ├── node.go
│ │ └── webhook
│ │ ├── mutating.go
│ │ └── validate.go
│ ├── k8s
│ ├── lock
│ ├── logger
│ ├── metrics
│ ├── profiling
│ ├── schema
│ └── types
├── test
├── tools
└── vendor
Describe the version
0.1.0 rc1
Describe the bug
A clear and concise description of what the bug is.
{
"msg":"Reconciler error%!(EXTRA []interface {}=[])",
"error":"EgressGateway.egressgateway.spidernet.io "default" is invalid: status.nodeList.interfaceStatus: Invalid value: "null": status.nodeList.interfaceStatus in body must be of type array: "null"
}
Fix in #179
the egress need rp_filter=0
it could refer to cilium code
https://github.com/cilium/cilium/blob/master/tools/sysctlfix/main.go#L39
Warning: spec.template.spec.affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms[1].matchExpressions[0].key: beta.kubernetes.io/os is deprecated since v1.14; use "kubernetes.io/os" instead
The `save-state` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Describe the version
Describe the bug
A clear and concise description of what the bug is.
workstation:~$ ip r show table 50
default
nexthop via 192.200.168.78 dev egress.vxlan weight 1
nexthop via 192.200.230.246 dev egress.vxlan weight 1
workstation:~$ ip r show table 50
default via 192.200.168.78 dev egress.vxlan
Hwo To Reproduce
Steps to reproduce the issue:
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots and log
If applicable, add screenshots and log to help explain your problem.
Additional context
Add any other context about the problem here.
customize the snat of egress source ip
Describe the version
v0.1.0
Describe the bug
root@dual-worker2:/#
root@dual-worker2:/# iptables -t nat -nvL POSTROUTING
Chain POSTROUTING (policy ACCEPT 6450 packets, 389K bytes)
pkts bytes target prot opt in out source destination
6461 389K KUBE-POSTROUTING all -- * * 0.0.0.0/0 0.0.0.0/0 /* kubernetes postrouting rules */
0 0 DOCKER_POSTROUTING all -- * * 0.0.0.0/0 172.18.0.1
6294 379K FLANNEL-POSTRTG all -- * * 0.0.0.0/0 0.0.0.0/0 /* flanneld masq */
# After the agent is restarted, the ACCEPT rule is restored. This problem may also exist in other ACCEPT rules
root@dual-worker2:/# iptables -t nat -nvL POSTROUTING
Chain POSTROUTING (policy ACCEPT 6484 packets, 391K bytes)
pkts bytes target prot opt in out source destination
0 0 ACCEPT all -- * * 0.0.0.0/0 0.0.0.0/0 /* egw:OucywG_GSKckREz8 */ mark match 0x12000000
6496 392K KUBE-POSTROUTING all -- * * 0.0.0.0/0 0.0.0.0/0 /* kubernetes postrouting rules */
0 0 DOCKER_POSTROUTING all -- * * 0.0.0.0/0 172.18.0.1
6328 381K FLANNEL-POSTRTG all -- * * 0.0.0.0/0 0.0.0.0/0 /* flanneld masq */
root@dual-worker2:/#
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.