Files
kubernetes-course/istio
Edward Viaene f0806a4502 istio egress
2018-09-21 14:19:32 +00:00
..
2018-09-21 14:19:32 +00:00
2018-09-03 14:02:33 +00:00
2018-09-15 20:19:49 +00:00
2018-09-15 20:19:49 +00:00
2018-09-12 15:49:02 +00:00
2018-09-12 15:49:02 +00:00
2018-09-11 14:39:12 +00:00
2018-09-11 14:39:12 +00:00
2018-09-11 14:39:12 +00:00
2018-09-10 13:32:13 +00:00
2018-09-05 09:04:51 +00:00
2018-09-05 09:04:51 +00:00
2018-09-10 13:32:13 +00:00
2018-09-05 09:04:51 +00:00
2018-09-21 14:19:32 +00:00

istio

Kops configuration

kops edit cluster kubernetes.newtech.academy

Add:

  kubeAPIServer:
    admissionControl:
    - NamespaceLifecycle
    - LimitRanger
    - ServiceAccount
    - PersistentVolumeLabel
    - DefaultStorageClass
    - DefaultTolerationSeconds
    - MutatingAdmissionWebhook
    - ValidatingAdmissionWebhook
    - ResourceQuota
    - NodeRestriction
    - Priority

download (1.0.2):

cd ~
wget https://github.com/istio/istio/releases/download/1.0.2/istio-1.0.2-linux.tar.gz
tar -xzvf istio-1.0.2-linux.tar.gz
cd istio-1.0.2
echo 'export PATH="$PATH:/home/ubuntu/istio-1.0.2/bin"' >> ~/.profile

Download (latest):

cd ~
curl -L https://git.io/getLatestIstio | sh -
echo 'export PATH="$PATH:/home/ubuntu/istio-1.0.2/bin"' >> ~/.profile # change 1.0.2 in your version
cd istio-1.0.2 # change 1.0.2 in your version

Istio install

Apply CRDs:

kubectl apply -f ~/istio-1.0.2/install/kubernetes/helm/istio/templates/crds.yaml

Wait a few seconds.

Option 1: with no mutual TLS authentication

kubectl apply -f ~/istio-1.0.2/install/kubernetes/istio-demo.yaml

Option 2: or with mutual TLS authentication

kubectl apply -f ~/istio-1.0.2/install/kubernetes/istio-demo-auth.yaml

Example app

Example app (from istio)

export PATH="$PATH:/home/ubuntu/istio-1.0.2/bin"
kubectl apply -f <(istioctl kube-inject -f samples/bookinfo/platform/kube/bookinfo.yaml)

Hello world app

export PATH="$PATH:/home/ubuntu/istio-1.0.2/bin"
kubectl apply -f <(istioctl kube-inject -f helloworld.yaml)
kubectl apply -f helloworld-gw.yaml

Mutual TLS example

Create pods, services, destinationrules, virtualservices

kubectl create -f <(istioctl kube-inject -f helloworld-tls.yaml)
kubectl create -f helloworld-legacy.yaml

End-user authentication

kubectl create -f <(istioctl kube-inject -f helloworld-jwt.yaml)
kubectl create -f helloworld-jwt-enable.yaml