run bookinfo with microk8s istio

microk8s enable istio
snap alias microk8s.kubectl mk
mk create namespace bookinfo
mk label namespace bookinfo istio-injection=enabled
mk config set-context --current --namespace=bookinfo
mk apply -f
mk apply -f
mk apply -f
mk apply -f
mk get virtualservices
NAME       GATEWAYS               HOSTS   AGE
bookinfo   ["bookinfo-gateway"]   ["*"]   15m
mk get gateway
NAME               AGE
bookinfo-gateway   15m
mk get pod -l app=ratings --show-labels
NAME           ...   LABELS
ratings-v1-xxx ...   app=ratings,...
mk exec "$(mk get pod -l app=ratings -o jsonpath='{.items[0]}')" -c ratings -- curl -sS productpage:9080/productpage | grep -o "<title>.*</title>" 
<title>Simple Bookstore App</title>

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.