mirror of https://github.com/istio/istio.io.git
parent
6fe38a178d
commit
a30c602951
|
|
@ -86,18 +86,6 @@ Bookinfo 应用中的几个微服务是由不同的编程语言编写的。
|
|||
$ kubectl apply -f @samples/bookinfo/platform/kube/bookinfo.yaml@
|
||||
{{< /text >}}
|
||||
|
||||
{{< warning >}}
|
||||
如果您在安装过程中禁用了 Sidecar
|
||||
自动注入功能而选择[手动注入 Sidecar](/zh/docs/setup/additional-setup/sidecar-injection/#manual-sidecar-injection),
|
||||
请在部署应用之前使用 [`istioctl kube-inject`](/zh/docs/reference/commands/istioctl/#istioctl-kube-inject)
|
||||
命令修改 `bookinfo.yaml` 文件。
|
||||
|
||||
{{< text bash >}}
|
||||
$ kubectl apply -f <(istioctl kube-inject -f @samples/bookinfo/platform/kube/bookinfo.yaml@)
|
||||
{{< /text >}}
|
||||
|
||||
{{< /warning >}}
|
||||
|
||||
上面这条命令会启动 `bookinfo` 应用架构图中显示的全部四个服务。
|
||||
也会启动三个版本的 reviews 服务:v1、v2 以及 v3。
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
title: 在 productpage 启用 Istio
|
||||
overview: 在一个微服务上部署 Istio 控制平面并启用 Istio。
|
||||
weight: 60
|
||||
|
||||
owner: istio/wg-docs-maintainers
|
||||
test: no
|
||||
---
|
||||
|
|
@ -23,9 +22,8 @@ test: no
|
|||
1. 重新部署 `productpage` 微服务,启用 Istio:
|
||||
|
||||
{{< tip >}}
|
||||
本教程为了教学目的将会逐步演示如何手动注入 Sidecar 启用 Istio,
|
||||
但是[自动注入 Sidecar](/zh/docs/setup/additional-setup/sidecar-injection/#automatic-sidecar-injection)
|
||||
更加便捷。
|
||||
本教程步骤演示了手动 Sidecar 注入,以演示如何逐个服务启用 Istio 以用于教学目的。
|
||||
[自动 Sidecar 注入](/zh/docs/setup/additional-setup/sidecar-injection/#automatic-sidecar-injection)是推荐用于生产用途的方法。
|
||||
{{< /tip >}}
|
||||
|
||||
{{< text bash >}}
|
||||
|
|
|
|||
|
|
@ -29,39 +29,20 @@ test: yes
|
|||
|
||||
1. 安装 `ratings` 服务的 `v2` 版本。
|
||||
|
||||
如果使用的是启用了 Sidecar 自动注入的集群,可以使用 `kubectl` 进行服务部署:
|
||||
|
||||
{{< text bash >}}
|
||||
$ kubectl apply -f @samples/bookinfo/platform/kube/bookinfo-ratings-v2.yaml@
|
||||
serviceaccount/bookinfo-ratings-v2 created
|
||||
deployment.apps/ratings-v2 created
|
||||
{{< /text >}}
|
||||
|
||||
如果使用手工的 Sidecar 注入方式,就需要使用下面的命令:
|
||||
|
||||
{{< text bash >}}
|
||||
$ kubectl apply -f <(istioctl kube-inject -f @samples/bookinfo/platform/kube/bookinfo-ratings-v2.yaml@)
|
||||
deployment "ratings-v2" configured
|
||||
{{< /text >}}
|
||||
|
||||
1. 安装 `mongodb` 服务:
|
||||
|
||||
如果使用的是启用了 Sidecar 自动注入的集群,可以使用 `kubectl` 进行服务部署:
|
||||
|
||||
{{< text bash >}}
|
||||
$ kubectl apply -f @samples/bookinfo/platform/kube/bookinfo-db.yaml@
|
||||
service/mongodb created
|
||||
deployment.apps/mongodb-v1 created
|
||||
{{< /text >}}
|
||||
|
||||
如果使用手工的 Sidecar 注入方式,就需要使用下面的命令:
|
||||
|
||||
{{< text bash >}}
|
||||
$ kubectl apply -f <(istioctl kube-inject -f @samples/bookinfo/platform/kube/bookinfo-db.yaml@)
|
||||
service "mongodb" configured
|
||||
deployment "mongodb-v1" configured
|
||||
{{< /text >}}
|
||||
|
||||
1. Bookinfo 示例部署了每个微服务的多个版本,因此您将首先创建目标规则定义每个版本对应的服务子集,
|
||||
以及每个子集的负载均衡策略。
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue