Istio 1.0.1 作为 8 月份的版本已经发布,主要修复了 1.0 版本发布以来发现的一些关键 Issue. 官网的 release note ( https://istio.io/about/notes/1.0.1/ )列出了 Istio1.0 和 1.0.1 的差别。
Istio 涉及的组件和 CRD 较多, Istio 1.0 中包含了 51 个 CRD,组件包括pilot,galley,policy,telemetry,citadel和许多插件, 对想快速试用 Istio 的同学来说比较困难。
Istio 1.0.1 允许部署一个仅包含 Pilot 组件的最小轻量级的 Istio 。对想快速上手 Istio 和只想使用 Istio 流量治理功能的同学带来了福音。 Istio 的流量治理功能非常强大,包括配置请求路由, 设置请求超时 ,重试,熔断,故障注入,实现灰度发布等。
下面让我们一起看下如何安装一个最小化的 Istio:
首先需要一个已经安装了 Kubernetes 的环境,并下载 Istio1.0.1 版本( https://github.com/istio/istio/releases/tag/1.0.1 )。
步骤:
1. 如果使用 2.10.0 之前的 Helm 版本,可以通过 kubectl apply 命令安装 Istio 的 Custom Resource Definitions ,等待几秒直到 CRDs 提交至 kube-apiserver:
kubectl apply -f install/kubernetes/helm/istio/templates/crds.yaml
2. 通过 helm template 安装,渲染 Istio 核心组件到 istio-minimal.yaml ( Kubernetes manifest 文件) :
helm template install/kubernetes/helm/istio --name istio --namespace istio-system \
--set security.enabled=false \
--set ingress.enabled=false \
--set gateways.istio-ingressgateway.enabled=false \
--set gateways.istio-egressgateway.enabled=false \
--set galley.enabled=false \
--set sidecarInjectorWebhook.enabled=false \
--set mixer.enabled=false \
--set prometheus.enabled=false \
--set global.proxy.envoyStatsd.enabled=false \
--set pilot.sidecar=false > $HOME/istio-minimal.yaml
3. 创建 istio-system 的命名空间:
kubectl create namespace istio-system
4. 通过第 2 步生成的 manifest 安装 pilot 组件:
kubectl apply -f $HOME/istio-minimal.yaml
5.
检查
istio-pilot-*
pod
是否部署成功:
kubectl get pods -n istio-system
NAME READY STATUS RESTARTS AGE
istio-pilot-58c65f74bc-2f5xn 1/1 Running 0 1m
只需要 5 步就可以成功安装一个最小化的 Istio ,是不是很简单?赶快尝试一下吧,
最后卸载 Istio 也很方便:
kubectl delete -f $HOME/istio-minimal.yaml
kubectl delete -f install/kubernetes/helm/istio/templates/crds.yaml -n istio-system
https://www.huaweicloud.com/product/cce.html
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/31543630/viewspace-2213974/ ,如需转载,请注明出处,否则将追究法律责任。