You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Your Kubernetes cluster includes [dual-stack](/docs/concepts/services-networking/dual-stack/) networking, which means that cluster networking lets you use either address family. In a cluster, the control plane can assign both an IPv4 address and an IPv6 address to a single {{< glossary_tooltip text="Pod" term_id="pod" >}} or a {{< glossary_tooltip text="Service" term_id="service" >}}.
19
+
Your Kubernetes cluster includes [dual-stack](/docs/concepts/services-networking/dual-stack/)
20
+
networking, which means that cluster networking lets you use either address family.
21
+
In a cluster, the control plane can assign both an IPv4 address and an IPv6 address to a single
22
+
{{< glossary_tooltip text="Pod" term_id="pod" >}} or a {{< glossary_tooltip text="Service" term_id="service" >}}.
You need to have installed the {{< glossary_tooltip text="kubeadm" term_id="kubeadm" >}} tool, following the steps from [Installing kubeadm](/docs/setup/production-environment/tools/kubeadm/install-kubeadm/).
35
+
You need to have installed the {{< glossary_tooltip text="kubeadm" term_id="kubeadm" >}} tool,
36
+
following the steps from [Installing kubeadm](/docs/setup/production-environment/tools/kubeadm/install-kubeadm/).
For each server that you want to use as a {{< glossary_tooltip text="node" term_id="node" >}}, make sure it allows IPv6 forwarding. On Linux, you can set this by running run `sysctl -w net.ipv6.conf.all.forwarding=1` as the root user on each server.
42
+
For each server that you want to use as a {{< glossary_tooltip text="node" term_id="node" >}},
43
+
make sure it allows IPv6 forwarding. On Linux, you can set this by running run
44
+
`sysctl -w net.ipv6.conf.all.forwarding=1` as the root user on each server.
`advertiseAddress` in InitConfiguration specifies the IP address that the API Server will advertise it is listening on. The value of `advertiseAddress` equals the `--apiserver-advertise-address` flag of `kubeadm init`
121
+
`advertiseAddress` in InitConfiguration specifies the IP address that the API Server
122
+
will advertise it is listening on. The value of `advertiseAddress` equals the
123
+
`--apiserver-advertise-address`flag of `kubeadm init`.
114
124
115
125
Run kubeadm to initiate the dual-stack control plane node:
The kube-controller-manager flags `--node-cidr-mask-size-ipv4|--node-cidr-mask-size-ipv6` are set with default values. See [configure IPv4/IPv6 dual stack](/docs/concepts/services-networking/dual-stack#configure-ipv4-ipv6-dual-stack).
138
+
The kube-controller-manager flags `--node-cidr-mask-size-ipv4|--node-cidr-mask-size-ipv6`
139
+
are set with default values. See [configure IPv4/IPv6 dual stack](/docs/concepts/services-networking/dual-stack#configure-ipv4-ipv6-dual-stack).
# change auth info above to match the actual token and CA certificate hash for your cluster
195
+
-->
179
196
```yaml
180
197
apiVersion: kubeadm.k8s.io/v1beta3
181
198
kind: JoinConfiguration
@@ -196,7 +213,9 @@ nodeRegistration:
196
213
```
197
214
198
215
<!--
199
-
`advertiseAddress`in JoinConfiguration.controlPlane specifies the IP address that the API Server will advertise it is listening on. The value of `advertiseAddress` equals the `--apiserver-advertise-address` flag of `kubeadm join`.
216
+
`advertiseAddress`in JoinConfiguration.controlPlane specifies the IP address that the
217
+
API Server will advertise it is listening on. The value of `advertiseAddress` equals
218
+
the `--apiserver-advertise-address` flag of `kubeadm join`.
200
219
-->
201
220
JoinConfiguration.controlPlane 中的 `advertiseAddress` 设定 API 服务器将公告自身要监听的
Copy file name to clipboardExpand all lines: content/zh-cn/docs/setup/production-environment/tools/kubespray.md
+43-17Lines changed: 43 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,14 +12,18 @@ weight: 30
12
12
<!-- overview -->
13
13
14
14
<!--
15
-
This quickstart helps to install a Kubernetes cluster hosted on GCE, Azure, OpenStack, AWS, vSphere, Equinix Metal (formerly Packet), Oracle Cloud Infrastructure (Experimental) or Baremetal with [Kubespray](https://github.com/kubernetes-sigs/kubespray).
15
+
This quickstart helps to install a Kubernetes cluster hosted on GCE, Azure, OpenStack,
16
+
AWS, vSphere, Equinix Metal (formerly Packet), Oracle Cloud Infrastructure (Experimental)
17
+
or Baremetal with [Kubespray](https://github.com/kubernetes-sigs/kubespray).
Kubespray is a composition of [Ansible](https://docs.ansible.com/) playbooks, [inventory](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/ansible.md#inventory), provisioning tools, and domain knowledge for generic OS/Kubernetes clusters configuration management tasks.
24
+
Kubespray is a composition of [Ansible](https://docs.ansible.com/) playbooks,
provisioning tools, and domain knowledge for generic OS/Kubernetes clusters configuration management tasks.
23
27
24
28
Kubespray provides:
25
29
-->
@@ -65,7 +69,8 @@ Kubespray 提供:
65
69
- 持续集成测试
66
70
67
71
<!--
68
-
To choose a tool which best fits your use case, read [this comparison](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/comparisons.md) to
72
+
To choose a tool which best fits your use case, read
73
+
[this comparison](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/comparisons.md) to
69
74
[kubeadm](/docs/reference/setup-tools/kubeadm/) and [kops](/docs/setup/production-environment/tools/kops/).
70
75
-->
71
76
要选择最适合你的用例的工具,请阅读
@@ -95,8 +100,11 @@ Provision servers with the following [requirements](https://github.com/kubernete
95
100
* The target servers must have **access to the Internet** in order to pull docker images. Otherwise, additional configuration is required See ([Offline Environment](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/offline-environment.md))
96
101
* The target servers are configured to allow **IPv4 forwarding**.
97
102
* If using IPv6 for pods and services, the target servers are configured to allow **IPv6 forwarding**.
98
-
* The **firewalls are not managed**, you'll need to implement your own rules the way you used to. in order to avoid any issue during deployment you should disable your firewall.
99
-
* If kubespray is run from non-root user account, correct privilege escalation method should be configured in the target servers. Then the `ansible_become` flag or command parameters `--become` or `-b` should be specified.
103
+
* The **firewalls are not managed**, you'll need to implement your own rules the way you used to.
104
+
in order to avoid any issue during deployment you should disable your firewall.
105
+
* If kubespray is run from non-root user account, correct privilege escalation method
106
+
should be configured in the target servers. Then the `ansible_become` flag or command
107
+
parameters `--become` or `-b` should be specified.
After you provision your servers, create an [inventory file for Ansible](https://docs.ansible.com/ansible/latest/network/getting_started/first_inventory.html). You can do this manually or via a dynamic inventory script. For more information, see "[Building your own inventory](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/getting-started.md#building-your-own-inventory)".
137
+
After you provision your servers, create an
138
+
[inventory file for Ansible](https://docs.ansible.com/ansible/latest/network/getting_started/first_inventory.html).
139
+
You can do this manually or via a dynamic inventory script. For more information,
140
+
see "[Building your own inventory](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/getting-started.md#building-your-own-inventory)".
130
141
131
142
### (3/5) Plan your cluster deployment
132
143
@@ -156,7 +167,7 @@ Kubespray 能够自定义部署的许多方面:
156
167
* {{< glossary_tooltip term_id="cri-o" >}}
157
168
* Certificate generation methods
158
169
-->
159
-
* 选择部署模式:kubeadm 或非 kubeadm
170
+
* 选择部署模式:kubeadm 或非 kubeadm
160
171
* CNI(网络)插件
161
172
* DNS 配置
162
173
* 控制平面的选择:本机/可执行文件或容器化
@@ -169,7 +180,10 @@ Kubespray 能够自定义部署的许多方面:
169
180
* 证书生成方式
170
181
171
182
<!--
172
-
Kubespray customizations can be made to a [variable file](https://docs.ansible.com/ansible/latest/user_guide/playbooks_variables.html). If you are getting started with Kubespray, consider using the Kubespray defaults to deploy your cluster and explore Kubernetes.
Cluster deployment using [ansible-playbook](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/getting-started.md#starting-custom-deployment).
Large deployments (100+ nodes) may require [specific adjustments](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/large-deployments.md) for best results.
@@ -204,7 +221,11 @@ Large deployments (100+ nodes) may require [specific adjustments](https://github
204
221
<!--
205
222
### (5/5) Verify the deployment
206
223
207
-
Kubespray provides a way to verify inter-pod connectivity and DNS resolve with [Netchecker](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/netcheck.md). Netchecker ensures the netchecker-agents pods can resolve DNS requests and ping each over within the default namespace. Those pods mimic similar behavior as the rest of the workloads and serve as cluster health indicators.
224
+
Kubespray provides a way to verify inter-pod connectivity and DNS resolve with
You can add worker nodes from your cluster by running the scale playbook. For more information, see "[Adding nodes](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/getting-started.md#adding-nodes)".
231
-
You can remove worker nodes from your cluster by running the remove-node playbook. For more information, see "[Remove nodes](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/getting-started.md#remove-nodes)".
251
+
You can add worker nodes from your cluster by running the scale playbook. For more information,
252
+
see "[Adding nodes](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/getting-started.md#adding-nodes)".
253
+
You can remove worker nodes from your cluster by running the remove-node playbook. For more information,
254
+
see "[Remove nodes](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/getting-started.md#remove-nodes)".
232
255
-->
233
256
### 扩展集群 {#scale-your-cluster}
234
257
@@ -240,7 +263,8 @@ You can remove worker nodes from your cluster by running the remove-node playboo
240
263
<!--
241
264
### Upgrade your cluster
242
265
243
-
You can upgrade your cluster by running the upgrade-cluster playbook. For more information, see "[Upgrades](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/upgrades.md)".
266
+
You can upgrade your cluster by running the upgrade-cluster playbook. For more information,
267
+
see "[Upgrades](https://github.com/kubernetes-sigs/kubespray/blob/master/docs/upgrades.md)".
244
268
-->
245
269
### 升级集群 {#upgrade-your-cluster}
246
270
@@ -250,7 +274,8 @@ You can upgrade your cluster by running the upgrade-cluster playbook. For more i
250
274
<!--
251
275
## Cleanup
252
276
253
-
You can reset your nodes and wipe out all components installed with Kubespray via the [reset playbook](https://github.com/kubernetes-sigs/kubespray/blob/master/reset.yml).
277
+
You can reset your nodes and wipe out all components installed with Kubespray
278
+
via the [reset playbook](https://github.com/kubernetes-sigs/kubespray/blob/master/reset.yml).
254
279
-->
255
280
## 清理 {#cleanup}
256
281
@@ -267,7 +292,8 @@ When running the reset playbook, be sure not to accidentally target your product
267
292
<!--
268
293
## Feedback
269
294
270
-
* Slack Channel: [#kubespray](https://kubernetes.slack.com/messages/kubespray/) (You can get your invite [here](https://slack.k8s.io/)).
0 commit comments