Istio 101 : How is the envoy proxy side car added to our pods/deployments



Istio uses kubernetes 
admission webhooks to add a sidecar into an existing deployment of pods.

We start by going into the istio namespace where we want to add the envoy side car - to the pods living in that namespace - using the below command:


All the subsequent "kubectl" commands will take place in the namespace listed in the context "istio-context".

The "config" file has the following format:


The commands will also use the credentials of the user "dev".

We create a deployment of pods in our namespace "istio-ns", and we check if the envoy proxy sidecar was added to our pods.

Below is our simple deployment example:


We run it using the below command:


Then we check the Yaml file of one of the deployed pods using the below command which outputs the definition of the pod in a Yaml format:


We get our pod's name using the "kubectl get pods" command.

Below is our updated Yaml file of our pod:

The "istio-sidecar-injectormutating admission webhook is responsible for adding the proxy side car to our pods.

To check it, we could use the below command:




Comments

Leave as a comment:

Archive