# 集群构建

集群构建的方式有很多，官方提供`kubeadm` 可以很方便的构建，相关文档可以直接看官方提供的 [Using kubeadm to Create a Cluster](https://kubernetes.io/docs/setup/independent/create-cluster-kubeadm/)。

{% hint style="info" %}
`kubeadm` 已经 GA 了，生产环境用户可以选择这种方式部署。不过，还是建议手动部署一遍 Kubernetes 集群，加深对 Kubernetes 整个运维架构的理解，也方便自行定制。
{% endhint %}

本章节会介绍以下两种集群构建方式：

* [从头开始构建一个 Kubernetes 集群](broken://pages/-LoAvkA_3Dyg8WBUqpsg)
* [通过 Ansible 自动构建 Kubernetes 集群 kubespray](https://github.com/kubernetes-sigs/kubespray)
  * 此处 Ansible 自动构建 Kubernetes 集群，给的项目为 kubespray，已经非常成熟，可以借鉴该项目自行定制

另外，如果有本地运行 Kubernetes 的需求，可以直接使用 [Minikube](https://github.com/kubernetes/minikube) 达到快速构建的目的，具体可以参考官方介绍。


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://wiki.opskumu.com/kubernetes/install.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
