-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
doc: SOFAMesh setup quick start in Kubernetes #142
Merged
Merged
Changes from 4 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
09f4167
Update _index.md
JamazRuan 32b2a3e
create new file for sofa mesh setup doc
4621fce
remove zookeeper doc
02cecbf
change aliases of sofa mesh setup
460f10b
change style
d311b51
change style
6e090d1
Merge branch 'master' into doc/sofa-mesh-doc
mergify[bot] File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
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
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 |
---|---|---|
@@ -0,0 +1,82 @@ | ||
--- | ||
title: "在 Kubernetes 中快速开始" | ||
aliases: "/sofa-mesh/docs/sofa-mesh-setup" | ||
--- | ||
|
||
JamazRuan marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
|
||
本文旨在描述如何在 Kubernetes 快速开始安装和配置 Istio。 | ||
SOFA Mosn 不仅可以支持 Istio 标准的部署模式,也能支持单方面的 Inbound Sidecar,Outbound Sidecar的部署模式,满足用户的各种需求。 | ||
|
||
## 前置要求 | ||
|
||
- Kubernetes | ||
- 安装helm,参考:https://github.com/helm/helm/blob/master/docs/install.md | ||
|
||
## 安装步骤 | ||
|
||
1. 下载最新的 release 包 | ||
2. 解压安装文件,并且进入解压后的路径,安装路径包含: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 请不要将有序列表和无序列表混合使用,将导致HTML渲染错误。 |
||
- 示例应用路径 `samples/` | ||
- /bin 路径下应该能找到 istioctl 客户端可执行文件,istioctl 可用于创建路由规则和策略 | ||
- 配置文件 istion.VERSION | ||
3. 把 Istio 的 bin 路径添加到系统的 PATH。比如,在 Linux 系统下执行如下命令: | ||
```bash | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 列表中不要出现代码片段,将导致 HTML 渲染错误。 |
||
export PATH=$PWD/bin;$PATH | ||
``` | ||
|
||
4. 创建命名空间 | ||
|
||
```bash | ||
kubectl create namespace istio-system | ||
``` | ||
|
||
5. 使用helm安装istio CRD | ||
|
||
```bash | ||
helm template install/kubernetes/helm/istio-init --name istio-init --namespace istio-system | kubectl apply -f - | ||
``` | ||
|
||
6. 使用helm安装各个组件 | ||
|
||
```bash | ||
helm template install/kubernetes/helm/istio --name istio --namespace istio-system | kubectl apply -f - | ||
``` | ||
|
||
7. 确认所有 pod 都在运行中 | ||
|
||
```bash | ||
kubectl get pod -n istio-system | ||
``` | ||
|
||
|
||
## 部署应用程序 | ||
|
||
现在开始部署 Bookinfo 示例程序 | ||
为 default 命名空间打上标签 istio-injection=enabled,实现 Sidecar 自动注入 | ||
|
||
```bash | ||
kubectl label namespace default istio-injection=enabled | ||
``` | ||
|
||
使用 kubectl 部署Bookinfo的服务 | ||
|
||
```bash | ||
kubectl apply -f samples/bookinfo/platform/kube/bookinfo.yaml | ||
``` | ||
|
||
确认所有的服务和 Pod 都已经正确的定义和启动 | ||
|
||
```bash | ||
kubectl get services | ||
|
||
kubectl get pods | ||
``` | ||
|
||
## 卸载 Istio | ||
|
||
```bash | ||
helm template install/kubernetes/helm/istio --name istio --namespace istio-system | kubectl delete -f - | ||
kubectl delete namespace istio-system | ||
``` | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
aliases 的值可以是数组,用途是重定向,请将删除的 URL 重定向到这里,可以这样配置: