Running Istio 1.5 on Minikube

Istio 1.5 is out. Istio took a very bald and big move. Istio decided to move away from microservices. Considering istio use case it makes lots of sense. As you go with microservice architecture you have several advantages like autonomy, use the best tool for the job(different languages), scale components independently, isolation and many others. However, microservices are not a free lunch and there is a downside from it. One of them is the DevOps engineering price to configure, provision, monitor and maintain several isolated services. The other one is complexity. Microservices are more complex than monolith systems. Istio took the move and went to from the microservices architecture with 5 services(Pilot, Cidatel, Telemetry, Policy, Galley, Injector) into 1 single service called istiod. This move made lots of sense.  Not only because it removed complexity but also make configuration, installation and upgrade much easier. I',m sure this move will drive more adoption.

Running Istio 1.5 in Minikube

Install kubectl

curl -LO https://storage.googleapis.com/kubernetes-release/release/`curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt`/bin/linux/amd64/kubectl
chmod +x ./kubectl
sudo mv ./kubectl /usr/local/bin/

Install Minikube

wget https://github.com/kubernetes/minikube/releases/download/v1.8.2/minikube-linux-amd64
chmod + xminikube-linux-amd64
sudo mv ./minikube-linux-amd64 /usr/local/bin/minikube

start minikube

minikube start --memory=16000 --cpus=6 -p istio15

install istioctl

wget https://github.com/istio/istio/releases/download/1.5.0/istioctl-1.5.0-linux.tar.gz
tar xfv istioctl-1.5.0-linux.tar.gz
chmod +x istioctl
sudo mv ./istioctl /usr/local/bin/

install istio

istioctl manifest apply --set profile=demo
kubectl label namespace default istio-injection=enabled

Deploy sample app

wget https://github.com/istio/istio/archive/1.5.0.tar.gz/
tar xfv istio-1.5.0.tar.gz
cd istio-1.5.0/
kubectl apply -f samples/bookinfo/platform/kube/bookinfo.yaml
kubectl apply -f samples/bookinfo/networking/bookinfo-gateway.yaml
kubectl exec -it $(kubectl get pod -l app=ratings -o jsonpath='{.items[0].metadata.name}') -c ratings -- curl productpage:9080/productpage | grep -o "<title>.*</title>"

export INGRESS_PORT=$(kubectl -n istio-system get service istio-ingressgateway -o jsonpath='{.spec.ports[?(@.name=="http2")].nodePort}')
export SECURE_INGRESS_PORT=$(kubectl -n istio-system get service istio-ingressgateway -o jsonpath='{.spec.ports[?(@.name=="https")].nodePort}')
export INGRESS_HOST=$(minikube ip -p istio15)
export GATEWAY_URL=$INGRESS_HOST:$INGRESS_PORT
minikube tunnel -p istio15
xdg-open http://$GATEWAY_URL/productpage
istioctl dashboard kiali

Check the dashboards

istioctl dashboard kiali
istioctl dashboard prometheus
istioctl dashboard jaeger
istioctl dashboard grafana
istioctl dashboard envoy productpage-v1-85b9bf9cd7-tcl69
istioctl dashboard controlz istiod-86798869b8-wv4hj -n istio-system
view raw istio-1.5.md hosted with ❤ by GitHub


There are some important things to keep in mind. First of all, I'm setting up 16GB for istio. Istio runs much better with more memory. It's possible to run it with 8GB if you like. If you are having issues, for sure is the memory. Crash loop back in Kubernetes most of the time is because of the lack of resources like memory.

Secondly, there are some commands that will require you to open new terminals like the minikube tunnel and dashboards. Keep in mind some of the dashboard commands like envoy and controlz require the pod name which will change, so do a kubectl get and pick the right pod name. Keep in mind istio is deployed in a different namespace called (istio-system) in order to access it via kubectl you need to pass -n istio-system at the end of each command.

Here are some screenshots of Istio 1.5 running on my machine.

kubectl get all (show all resources from the demo app)

kubectl get all -n istio-system (show all resources from istio namespace/installation)

istioctl dashboard kiali (show kiali service-mesh graph visualization of the demo app).

istioctl dashboard Prometheus (show Prometheus observability ui).

istioctl dashboard envoy $productpage_pod_name

istioctl dashboard controlz $istiod-pod-name -n istio-system

Product Page demo app running on my chrome

istioctl dashboard jaeger

istioctl dashbaord grafana

Istio 1.5 it's very sexy. One of the biggest downsides of istio just got fixed(complexity of configuration, maintained and upgrade). The only thing we still need to be paying attention to is overhead.  The last time I check was around 10ms. I'm sure istio will get faster and better.

Cheers,
Diego Pacheco


Popular posts from this blog

Having fun with Zig Language

C Unit Testing with Check

Cool Retro Terminal