-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
37 additions
and
163 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,10 +4,10 @@ The steps are listed in this doc to perform an Istio version upgrade with the op | |
|
||
## Istio Control Plane Upgrade | ||
|
||
Let us suppose that we have a [Kubernetes](https://kubernetes.io/) cluster with Istio 1.0.7, and we would like to upgrade our Istio components to Istio version 1.1.9. Here are the steps we need to perform to accomplish this with the operator: | ||
Let us suppose that we have a [Kubernetes](https://kubernetes.io/) cluster with Istio 1.1.11, and we would like to upgrade our Istio components to Istio version 1.2.2. Here are the steps we need to perform to accomplish this with the operator: | ||
|
||
1. Deploy a version of the operator which supports Istio 1.1.x | ||
2. Apply a [Custom Resource](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/) using Istio 1.1.9 components | ||
1. Deploy a version of the operator which supports Istio 1.2.x | ||
2. Apply a [Custom Resource](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/) using Istio 1.2.2 components | ||
|
||
What happens is that once the operator discerns that the Custom Resource it's watching has changed, it reconciles all Istio-related components in order to perform a control plane upgrade. | ||
|
||
|
@@ -20,14 +20,14 @@ What happens is that once the operator discerns that the Custom Resource it's wa | |
- Minikube v0.33.1+ or Kubernetes 1.10.0+ | ||
- `KUBECONFIG` set to an existing Kubernetes cluster | ||
|
||
If you already have Istio 1.0.x installed on your cluster you can skip the next section and can jump right to [Deploy sample BookInfo application](#deploy-sample-bookinfo-application). | ||
If you already have Istio 1.1.x installed on your cluster you can skip the next section and can jump right to [Deploy sample BookInfo application](#deploy-sample-bookinfo-application). | ||
|
||
#### Install Istio 1.0.7 | ||
#### Install Istio 1.1.11 | ||
|
||
We install Istio with our operator, so first we need to check out the `release-1.0` branch of our operator (this branch supports Istio versions before 1.1.0): | ||
We install Istio with our operator, so first we need to check out the `release-1.1` branch of our operator (this branch supports Istio versions before 1.2.0): | ||
```bash | ||
$ git clone [email protected]:banzaicloud/istio-operator.git | ||
$ git checkout release-1.0 | ||
$ git checkout release-1.1 | ||
``` | ||
|
||
**Install Istio Operator with make** | ||
|
@@ -46,16 +46,16 @@ Alternatively, if you just can't let go of Helm completely, you can deploy the o | |
|
||
```bash | ||
$ helm repo add banzaicloud-stable https://kubernetes-charts.banzaicloud.com | ||
$ helm install --name=istio-operator --namespace=istio-system --set-string operator.image.tag=0.0.11 banzaicloud-stable/istio-operator | ||
$ helm install --name=istio-operator --namespace=istio-system --set-string operator.image.tag=0.1.21 banzaicloud-stable/istio-operator | ||
``` | ||
|
||
*Note: As of now, the `0.0.11` tag is the latest version of our operator to support Istio versions 1.0.x.* | ||
*Note: As of now, the `0.1.21` tag is the latest version of our operator to support Istio versions 1.1.x.* | ||
|
||
**Apply the Custom Resource** | ||
|
||
Once you've applied the Custom Resource to your cluster, the operator will start reconciling all of Istio's components. | ||
|
||
There are some sample Custom Resource configurations in the `config/samples` folder. To deploy Istio 1.0.7 with its default configuration options, use the following command: | ||
There are some sample Custom Resource configurations in the `config/samples` folder. To deploy Istio 1.1.11 with its default configuration options, use the following command: | ||
|
||
```bash | ||
$ kubectl apply -n istio-system -f config/samples/istio_v1beta1_istio.yaml | ||
|
@@ -77,75 +77,24 @@ istio-sidecar-injector-596f8dddbb-gvzk9 1/1 Running 0 1m | |
istio-telemetry-7cbf75c5cf-wk4v8 2/2 Running 0 1m | ||
``` | ||
|
||
The `Istio` Custom Resource is showing `Available` in its status field and the Istio components are using `1.0.7` images : | ||
The `Istio` Custom Resource is showing `Available` in its status field and the Istio components are using `1.1.11` images : | ||
|
||
```bash | ||
$ kubectl describe istio -n istio-system istio | ||
Name: istio-sample | ||
Namespace: istio-system | ||
Labels: controller-tools.k8s.io=1.0 | ||
Annotations: kubectl.kubernetes.io/last-applied-configuration={"apiVersion":"istio.banzaicloud.io/v1beta1","kind":"Istio","metadata":{"annotations":{},"labels":{"controller-tools.k8s.io":"1.0"},"name":"istio-sampl... | ||
API Version: istio.banzaicloud.io/v1beta1 | ||
Kind: Istio | ||
Metadata: | ||
Creation Timestamp: 2019-03-31T10:07:22Z | ||
Finalizers: | ||
istio-operator.finializer.banzaicloud.io | ||
Generation: 2 | ||
Resource Version: 13101 | ||
Self Link: /apis/istio.banzaicloud.io/v1beta1/namespaces/istio-system/istios/istio-sample | ||
UID: c6a095da-539c-11e9-9080-42010a9a0136 | ||
Spec: | ||
Auto Injection Namespaces: | ||
default | ||
Citadel: | ||
Image: istio/citadel:1.0.7 | ||
Replica Count: 1 | ||
Galley: | ||
Image: istio/galley:1.0.7 | ||
Replica Count: 1 | ||
Gateways: | ||
Egress: | ||
Max Replicas: 5 | ||
Min Replicas: 1 | ||
Replica Count: 1 | ||
Ingress: | ||
Max Replicas: 5 | ||
Min Replicas: 1 | ||
Replica Count: 1 | ||
Include IP Ranges: * | ||
Mixer: | ||
Image: istio/mixer:1.0.7 | ||
Max Replicas: 5 | ||
Min Replicas: 1 | ||
Replica Count: 1 | ||
Mtls: false | ||
Pilot: | ||
Image: istio/pilot:1.0.7 | ||
Max Replicas: 5 | ||
Min Replicas: 1 | ||
Replica Count: 1 | ||
Trace Sampling: 1 | ||
Proxy: | ||
Image: istio/proxyv2:1.0.7 | ||
Sidecar Injector: | ||
Image: istio/sidecar_injector:1.0.7 | ||
Replica Count: 1 | ||
Tracing: | ||
Zipkin: | ||
Address: zipkin.jaeger-system:9411 | ||
Status: | ||
Error Message: | ||
Status: Available | ||
Events: <none> | ||
$ kubectl describe istio -n istio-system istio -o yaml | grep "image:" | ||
image: docker.io/istio/citadel:1.1.11 | ||
image: docker.io/istio/galley:1.1.11 | ||
image: docker.io/istio-mixer:1.1.11 | ||
image: docker.io/istio-pilot:1.1.11 | ||
image: docker.io/istio/proxyv2:1.1.11 | ||
image: docker.io/istio/sidecar_injector:1.1.11 | ||
``` | ||
|
||
#### Deploy sample BookInfo application | ||
|
||
Let's make sure that Istio 1.0.7 is properly installed with Istio's BookInfo application: | ||
Let's make sure that Istio 1.1.11 is properly installed with Istio's BookInfo application: | ||
|
||
```bash | ||
$ kubectl -n default apply -f https://raw.githubusercontent.com/istio/istio/release-1.0/samples/bookinfo/platform/kube/bookinfo.yaml | ||
$ kubectl -n default apply -f https://raw.githubusercontent.com/istio/istio/release-1.1/samples/bookinfo/platform/kube/bookinfo.yaml | ||
service "details" created | ||
deployment.extensions "details-v1" created | ||
service "ratings" created | ||
|
@@ -157,7 +106,7 @@ deployment.extensions "reviews-v3" created | |
service "productpage" created | ||
deployment.extensions "productpage-v1" created | ||
|
||
$ kubectl -n default apply -f https://raw.githubusercontent.com/istio/istio/release-1.0/samples/bookinfo/networking/bookinfo-gateway.yaml | ||
$ kubectl -n default apply -f https://raw.githubusercontent.com/istio/istio/release-1.1/samples/bookinfo/networking/bookinfo-gateway.yaml | ||
gateway.networking.istio.io "bookinfo-gateway" created | ||
virtualservice.networking.istio.io "bookinfo" created | ||
``` | ||
|
@@ -169,12 +118,12 @@ $ INGRESS_HOST=$(kubectl -n istio-system get service istio-ingressgateway -o jso | |
$ open http://$INGRESS_HOST/productpage | ||
``` | ||
|
||
#### Install Istio 1.1.9 | ||
#### Install Istio 1.2.2 | ||
|
||
To install Istio 1.1.9, first we need to check out the `release-1.1` branch of our operator (this branch supports the Istio 1.1.x versions): | ||
To install Istio 1.2.2, first we need to check out the `release-1.2` branch of our operator (this branch supports the Istio 1.2.x versions): | ||
```bash | ||
$ git clone [email protected]:banzaicloud/istio-operator.git | ||
$ git checkout release-1.1 | ||
$ git checkout release-1.2 | ||
``` | ||
|
||
> If you installed Istio operator with `make` in the previous section go to to `Install Istio Operator with make`, if you installed it with `helm` go to `Install Istio Operator with helm`. If you haven't installed Istio operator so far you can choose whichever install option you like. | ||
|
@@ -194,16 +143,16 @@ Alternatively, you can deploy the operator using a [Helm chart](https://github.c | |
|
||
```bash | ||
$ helm repo add banzaicloud-stable https://kubernetes-charts.banzaicloud.com | ||
$ helm upgrade istio-operator --install --namespace=istio-system --set-string operator.image.tag=0.1.19 banzaicloud-stable/istio-operator | ||
$ helm upgrade istio-operator --install --namespace=istio-system --set-string operator.image.tag=0.2.0 banzaicloud-stable/istio-operator | ||
``` | ||
|
||
*Note: As of now, the `0.1.19` tag is the latest version of our operator to support Istio versions 1.1.x.* | ||
*Note: As of now, the `0.2.0` tag is the latest version of our operator to support Istio versions 1.2.x.* | ||
|
||
**Apply the new Custom Resource** | ||
|
||
> If you've installed Istio 1.0.7 or earlier with the Istio operator, and if you check the logs of the operator pod at this point, you will see the following error message: `intended Istio version is unsupported by this version of the operator`. We need to update the Istio Custom Resource with Istio 1.1's components for the operator to be reconciled with the Istio control plane. | ||
> If you've installed Istio 1.1.11 or earlier with the Istio operator, and if you check the logs of the operator pod at this point, you will see the following error message: `intended Istio version is unsupported by this version of the operator`. We need to update the Istio Custom Resource with Istio 1.2's components for the operator to be reconciled with the Istio control plane. | ||
To deploy Istio 1.1.9 with its default configuration options, use the following command: | ||
To deploy Istio 1.2.2 with its default configuration options, use the following command: | ||
|
||
```bash | ||
$ kubectl apply -n istio-system -f config/samples/istio_v1beta1_istio.yaml | ||
|
@@ -225,94 +174,19 @@ istio-sidecar-injector-66cd99d8c8-bp4j7 1/1 Running 0 7m | |
istio-telemetry-7b667c5fbb-2lfdc 2/2 Running 0 7m | ||
``` | ||
|
||
The `Istio` Custom Resource is showing `Available` in its status field, and the Istio components are now using `1.1.9` images: | ||
The `Istio` Custom Resource is showing `Available` in its status field, and the Istio components are now using `1.2.2` images: | ||
|
||
```bash | ||
$ kubectl describe istio -n istio-system istio | ||
Name: istio-sample | ||
Namespace: istio-system | ||
Labels: controller-tools.k8s.io=1.0 | ||
Annotations: kubectl.kubernetes.io/last-applied-configuration={"apiVersion":"istio.banzaicloud.io/v1beta1","kind":"Istio","metadata":{"annotations":{},"labels":{"controller-tools.k8s.io":"1.0"},"name":"istio-sampl... | ||
API Version: istio.banzaicloud.io/v1beta1 | ||
Kind: Istio | ||
Metadata: | ||
Creation Timestamp: 2019-03-31T10:07:22Z | ||
Finalizers: | ||
istio-operator.finializer.banzaicloud.io | ||
Generation: 3 | ||
Resource Version: 21904 | ||
Self Link: /apis/istio.banzaicloud.io/v1beta1/namespaces/istio-system/istios/istio-sample | ||
UID: c6a095da-539c-11e9-9080-42010a9a0136 | ||
Spec: | ||
Auto Injection Namespaces: | ||
default | ||
Citadel: | ||
Image: docker.io/istio/citadel:1.1.9 | ||
Replica Count: 1 | ||
Control Plane Security Enabled: false | ||
Default Pod Disruption Budget: | ||
Enabled: true | ||
Exclude IP Ranges: | ||
Galley: | ||
Image: docker.io/istio/galley:1.1.9 | ||
Replica Count: 1 | ||
Gateways: | ||
Egress: | ||
Max Replicas: 5 | ||
Min Replicas: 1 | ||
Replica Count: 1 | ||
Service Annotations: | ||
Service Labels: | ||
Service Type: ClusterIP | ||
Ingress: | ||
Max Replicas: 5 | ||
Min Replicas: 1 | ||
Replica Count: 1 | ||
Service Annotations: | ||
Service Labels: | ||
Service Type: LoadBalancer | ||
K8s ingress: | ||
Enabled: false | ||
Include IP Ranges: * | ||
Mixer: | ||
Image: docker.io/istio/mixer:1.1.9 | ||
Max Replicas: 5 | ||
Min Replicas: 1 | ||
Replica Count: 1 | ||
Mtls: false | ||
Node Agent: | ||
Enabled: false | ||
Image: docker.io/istio/node-agent-k8s:1.1.9 | ||
Outbound Traffic Policy: | ||
Mode: ALLOW_ANY | ||
Pilot: | ||
Image: docker.io/istio/pilot:1.1.9 | ||
Max Replicas: 5 | ||
Min Replicas: 1 | ||
Replica Count: 1 | ||
Trace Sampling: 1 | ||
Proxy: | ||
Enable Core Dump: false | ||
Image: docker.io/istio/proxyv2:1.1.9 | ||
Proxy Init: | ||
Image: docker.io/istio/proxy_init:1.1.9 | ||
Sds: | ||
Enabled: false | ||
Sidecar Injector: | ||
Image: docker.io/istio/sidecar_injector:1.1.9 | ||
Replica Count: 1 | ||
Rewrite App HTTP Probe: true | ||
Tracing: | ||
Zipkin: | ||
Address: zipkin.istio-system:9411 | ||
Version: 1.1.9 | ||
Status: | ||
Error Message: | ||
Status: Available | ||
Events: <none> | ||
$ kubectl describe istio -n istio-system istio -o yaml | grep "image:" | ||
image: docker.io/istio/citadel:1.2.2 | ||
image: docker.io/istio/galley:1.2.2 | ||
image: docker.io/istio-mixer:1.2.2 | ||
image: docker.io/istio-pilot:1.2.2 | ||
image: docker.io/istio/proxyv2:1.2.2 | ||
image: docker.io/istio/sidecar_injector:1.2.2 | ||
``` | ||
|
||
At this point, your Istio control plane is upgraded to Istio 1.1.9 and your BookInfo application should still be available at: | ||
At this point, your Istio control plane is upgraded to Istio 1.2.2 and your BookInfo application should still be available at: | ||
```bash | ||
$ open http://$INGRESS_HOST/productpage | ||
``` | ||
|