Istio初探

Istio初探

前置环境:docker

一、安装k8s:
● https://segmentfault.com/a/1190000042204035
1、 https://github.com/gotok8s/k8s-docker-desktop-for-mac.git
2、 https://github.com/kubernetes/dashboard
3、 获取token
curl ‘http://127.0.0.1:8001/api/v1/namespaces/kubernetes-dashboard/serviceaccounts/admin-user/token’ -H “Content-Type:application/json” -X POST -d ‘{}’
4、 查看k8s dashboard
在这里插入图片描述

● 安装kubectl
1、 https://kubernetes.io/zh-cn/docs/tasks/tools/install-kubectl-macos/
● 关键结果:
1、 k8s dashboard
2、 kubectl

二、安装istio并完成bookinfo示例部署
● https://istio.io/latest/zh/docs/setup/getting-started/
1、 安装istio
2、 k8s部署bookinfo示例
配置1:https://raw.githubusercontent.com/istio/istio/release-1.14/samples/bookinfo/platform/kube/bookinfo.yaml 作用:定义service、deplotment
应用结构:
在这里插入图片描述

3、 植入istio,创建 https://istio.io/latest/zh/docs/concepts/traffic-management/#gateways,实现外部访问
配置2:https://raw.githubusercontent.com/istio/istio/release-1.14/samples/bookinfo/networking/bookinfo-gateway.yaml 作用:定义整体应用入口网关
在这里插入图片描述
4、 安装kiali dashboard
在这里插入图片描述

三、isitio特性——https://istio.io/latest/zh/docs/tasks/traffic-management/request-routing/
1、注册destination rule
配置3:https://raw.githubusercontent.com/istio/istio/release-1.14/samples/bookinfo/networking/destination-rule-all.yaml 作用:注册路由,保证服务发现
若未注册则无法发现服务
在这里插入图片描述

2、创建virtual service
配置4:https://raw.githubusercontent.com/istio/istio/release-1.14/samples/bookinfo/networking/virtual-service-all-v1.yaml
作用:定义virtual service作为默认服务,控制版本,例如reviews服务三个版本默认为v2版本,拓扑如下:
在这里插入图片描述

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值