Skip to content

Commit

Permalink
Merge pull request #3 from cybozu-go/fix-design
Browse files Browse the repository at this point in the history
Fix the design doc
  • Loading branch information
chez-shanpu authored Aug 20, 2024
2 parents 937a1d9 + eb49c0f commit 00b78a5
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions docs/design.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ flowchart LR
linkStyle 0,1,2 stroke: indianred;
kubelet -- " b-1 create pod " --> natClient
kubelet -- " b-2 send CNI Add " --> cniPlugin
kubelet -- " b-2 send CNI Add/Del " --> cniPlugin
cniPlugin -- " b-3 send RPC call " --> ponad
ponad -- " b-4 get Egress resource " --> egress
ponad -- " b-4 get NAT Client Pod resource " --> pod
Expand All @@ -64,8 +64,9 @@ Users can create a NAT Pod with a Egress Custom Resource.
When a Egress resource is created, the Egress Controller creates a NAT Pod and a ClusterIP Service (`a-1`, `a-2`).

When a user want to send a request with NAT, the user creates a NAT client Pod with an annotation.
Ponad which is deployed as daemonset, watches Pod resources.
When a Pod with the annotation is created, Ponad configures the Pod to be routed to NAT Pod via the ClusterIP Service. (`b-1`, `b-2`, `b-3`, `b-4`).
Ponad which is deployed as daemonset, watches Pod resources.
When a Pod with the annotation is created, Ponad configures the Pod to be routed to NAT Pod via the ClusterIP Service.
When a NAT client Pod is deleted, Pona CNI plugin is received a CNI Del and Ponad removes the configuration and NAT Pod removes the configuration corresponding to the NAT client (`b-1`, `b-2`, `b-3`, `b-4`).

A request from a NAT client Pod is routed to the NAT Pod via the ClusterIP Service, and the NAT Pod performs SNAT and sends the request to the external host.

Expand Down

0 comments on commit 00b78a5

Please sign in to comment.