How to push changes to Kubernestes Kube-proxy?

2/23/2018

I'm new to Kubernetes development, and I have a task to change some features in Kuberenetes services.

I have the Kubernetes local cluster, and also I have a testbed consisting of 4 RPI's, My first changes were done over Kubectl, and what I have done was cross compiling the binaries on my machine and then replacing the old binaries found in the RPI's (since compiling the code in the RPI's is time-consuming).

Now, I have reached a point where I have to update some changes to Kube-proxy, in the local cluster the binary files are in _output/bin, however in the real cluster the Kube-proxy is running in a container (for each node), so changing the binaries would need creating new Docker images and forcing Kubernetes to choose those images instead of the default ones (as far as I understood).

So My questions:

  1. What is the best/easiest way to push the changes on Kube-proxy on the running cluster?

  2. If I compiled the code in the RPI, the make will release a binary file of Kube-proxy, but how the cluster will take those changes?

Cluster Spec's:

  1. Kubernetes v1.9.

  2. OS hypriotos-v7+.

  3. Architecture arm 32-bit.

-- elia
kube-proxy
kubernetes

1 Answer

6/7/2018

All nodes should run kube-proxy. (Running kube-proxy on a “master” node is not strictly required, but being consistent is easier.) Obtain a binary as described for kubelet.

Arguments to consider:

If following the HTTPS security approach:

--master=https://$MASTER_IP
--kubeconfig=/var/lib/kube-proxy/kubeconfig

Otherwise, if taking the firewall-based security approach

--master=http://$MASTER_IP

Note that on some Linux platforms, you may need to manually install the conntrack package which is a dependency of kube-proxy, or else kube-proxy cannot be started successfully.

For more details on debugging kube-proxy problems, please refer to Debug Services

Source : https://kubernetes.io/docs/getting-started-guides/scratch/#kube-proxy

-- Arif A.
Source: StackOverflow