Skip to content

Commit 6d43268

Browse files
authored
support for direct server return (#204)
new annotation is added `kube-router.io/service.dsr=tunnel` to enable DSR Fixes #40
1 parent 4ca0afa commit 6d43268

File tree

2,809 files changed

+406345
-10472
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,809 files changed

+406345
-10472
lines changed

Documentation/README.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,22 @@ To enable hairpin traffic for Service `my-service`:
213213
kubectl annotate service my-service "kube-router.io/service.hairpin="
214214
```
215215

216+
### Direct server return
217+
218+
You can enable DSR(Direct Server Return) functionality per service. When enabled service endpoint
219+
will directly respond to the client. When DSR is enabled Kube-router will uses LVS's tunneling mode to achive this.
220+
221+
To enable DSR you need to annotate service with `kube-router.io/service.dsr=tunnel` annotation.
222+
223+
In the current implementation althouh annotation is enabled, DSR will be applicable only to the external IP's.
224+
225+
You will need to enable `hostIPC: true` and `hostPID: true` in kube-router daemonset manifest.
226+
Also host path `/var/run/docker.sock` must be made a volumemount to kube-router.
227+
228+
Above changes are required for kube-router to enter pod namespeace and create ipip tunnel in the pod and to
229+
assign the external IP to the VIP.
230+
231+
For an e.g manifest please look at [manifest](../daemonset/kubeadm-kuberouter-all-features-dsr.yaml) with DSR requirments enabled.
216232

217233
## BGP configuration
218234

0 commit comments

Comments
 (0)