From 2875957097d77d94eb1f5f508895482f7c6d8a64 Mon Sep 17 00:00:00 2001 From: wuyingjun Date: Wed, 15 Nov 2023 16:13:10 +0800 Subject: [PATCH] Modify Readme markdown Signed-off-by: wuyingjun --- README.md | 40 +++++++----------- README_zh.md | 35 +++++++-------- .../{knode-arch.png => clustertree-arch.png} | Bin 3 files changed, 32 insertions(+), 43 deletions(-) rename docs/images/{knode-arch.png => clustertree-arch.png} (100%) diff --git a/README.md b/README.md index b8d9a954f..81095d400 100644 --- a/README.md +++ b/README.md @@ -23,38 +23,17 @@ The Kosmos ClusterLink module currently includes the following key components: - `Multi-Cluster-Coredns`:Implements multi-cluster service discovery. - `Elector`:Elects the gateway node. -### Quick Start - -#### Start Locally - -The following command allows you to quickly run an experimental environment locally. This command will use kind (so Docker needs to be installed firstly) to create two Kubernetes clusters and deploy ClusterLink. -```Shell -./hack/local-up-clusterlink.sh -``` - -Verify if the service is running smoothly. -```Shell -kubectl --context=kind-cluster-host-local get pods -nclusterlink-system -kubectl --context=kind-cluster-member1-local get pods -nclusterlink-system -``` - -Verify if the cross-cluster network is connected. -```Shell -kubectl --context=kind-cluster-host-local exec -it -- ping -``` - - ## ClusterTree The Kosmos clustertree module realizes the tree-like scaling of Kubernetes and achieves cross-cluster orchestration of applications. -
+
Currently, it primarily supports the following ability: 1. **Full Compatibility with k8s API**: Users can interact with the host cluster's `kube-apiserver` using tools like `kubectl`, `client-go`, and others just like they normally would. However, the `Pods` are actually distributed across the entire multi-cloud, multi-cluster environment. 2. **Support for Stateful and k8s-native Applications**: In addition to stateless applications, Kosmos also facilitates the orchestration of stateful applications and k8s-native applications (interacting with `kube-apiserver`). Kosmos will automatically detect the storage and permission resources that `Pods`depend on, such as pv/pvc, sa, etc., and perform automatic bothway synchronization. 3. **Diverse Pod Topology Constraints**: Users can easily control the distribution of Pods within the global clusters, such as by region, availability zone, cluster, or node. This helps achieve high availability and improve resource utilization. -## Scheduler (Under Construction) +## Scheduler The Kosmos scheduling module is an extension developed on top of the Kubernetes scheduling framework, aiming to meet the container management needs in mixed-node and sub-cluster environments. It provides the following core features to enhance the flexibility and efficiency of container management: @@ -65,8 +44,21 @@ The Kosmos scheduling module is an extension developed on top of the Kubernetes 3. **Fine-grained Fragmented Resource Handling**: The Kosmos scheduling module intelligently detects fragmented resources within sub-clusters, effectively avoiding situations where pod deployment encounters insufficient resources in the sub-cluster. This helps ensure a more balanced allocation of resources across different nodes, enhancing system stability and performance. Whether building a hybrid cloud environment or requiring flexible deployment of workloads across different clusters, the Kosmos scheduling module serves as a reliable solution, assisting users in managing containerized applications more efficiently. -## Contact +## Quick Start +The following command allows you to quickly run an experimental environment with three clusters. +Install the control plane in the host cluster. +```Shell +kosmosctl install --cni calico --default-nic eth0 (We build a network tunnel based the network interface value passed by the arg default-nic) +``` +Join the two member clusters. +```Shell +kosmosctl join cluster --name cluster1 --kubeconfig ~/kubeconfig/cluster1-kubeconfig --cni calico --default-nic eth0 --enable-all +kosmosctl join cluster --name cluster2 --kubeconfig ~/kubeconfig/cluster2-kubeconfig --cni calico --default-nic eth0 --enable-all +``` +And then we can Use the Kosmos clusters like single cluster. + +## Contact If you have questions, feel free to reach out to us in the following ways: - [Email](mailto:wuyingjun@cmss.chinamobile.com) - [WeChat](./docs/images/kosmos-WechatIMG.jpg) diff --git a/README_zh.md b/README_zh.md index 3998bb2cd..f4df99343 100644 --- a/README_zh.md +++ b/README_zh.md @@ -23,33 +23,17 @@ Kosmos多集群网络模块目前包含以下几个关键组件: - `Multi-Cluster-Coredns`: 实现多集群服务发现; - `Elector`:负责gateway节点选举; -### 快速开始 - -#### 本地启动 -通过以下命令可以快速在本地运行一个实验环境,该命令将基于`kind`(因此需要先安装docker)创建两个k8s集群,并部署ClusterLink。 -```bash -./hack/local-up-clusterlink.sh -``` -检查服务是否正常运行 -```bash -kubectl --context=kind-cluster-host-local get pods -nclusterlink-system -kubectl --context=kind-cluster-member1-local get pods -nclusterlink-system -``` -确认跨集群网络是否打通 -```bash -kubectl --context=kind-cluster-host-local exec -it -- ping -``` ## 多集群管理编排 Kosmos多集群管理编排模块实现了Kubernetes的树形扩展和应用的跨集群编排。 -
+
目前主要支持以下功能: 1. **完全兼容k8s api**:用户可以像往常那样,使用 `kubectl`、`client-go`等工具与host集群的`kube-apiserver`交互,而`Pod`实际上是分布在整个多云多集群中。 2. **有状态应用、k8s-native应用支持**:除了无状态应用,Kosmos还支持对有状态应用和 k8s-native(与 `kube-apiserver`存在交互)应用的编排。Kosmos会自动检测`Pod`依赖的存储、权限资源,例如:pv/pvc、sa等,并自动进行双向同步。 3. **多样化Pod拓扑分布约束**:用户可以轻易的控制Pod在联邦集群中的分布,如:区域(Region)、可用区(Zone)、集群或者节点,有助于实现高可用并提升资源利用率。 -## 多集群调度(建设中) +## 多集群调度 Kosmos调度模块是基于Kubernetes调度框架的扩展开发,旨在满足混合节点和子集群环境下的容器管理需求。这一调度器经过精心设计与定制,提供了以下核心功能,以增强容器管理的灵活性和效率: 1. **灵活的节点和集群混合调度**: Kosmos调度模块允许用户依据自定义配置,轻松地将工作负载在真实节点和子集群之间智能地调度。这使得用户能够充分利用不同节点的资源,以确保工作负载在性能和可用性方面的最佳表现。基于该功能,Kosmos可以让工作负载实现灵活的跨云跨集群部署。 @@ -58,8 +42,21 @@ Kosmos调度模块是基于Kubernetes调度框架的扩展开发,旨在满足 无论是构建混合云环境还是需要在不同集群中进行工作负载的灵活部署,Kosmos调度模块都可作为可靠的解决方案,协助用户更高效地管理容器化应用。 -## 贡献者 +## 快速开始 +通过以下命令可以快速在本地运行一个三个集群的实验环境: +在主集群部署管理组件 +```bash +kosmosctl install --cni calico --default-nic eth0 (参数default-nic 表示基于哪个网卡创建网络隧道) +``` +加入两个子集群 +```bash +kosmosctl join cluster --name cluster1 --kubeconfig ~/kubeconfig/cluster1-kubeconfig --cni calico --default-nic eth0 --enable-all +kosmosctl join cluster --name cluster2 --kubeconfig ~/kubeconfig/cluster2-kubeconfig --cni calico --default-nic eth0 --enable-all +``` + +然后我们就可以像使用单集群一样去使用多集群了 +## 贡献者 diff --git a/docs/images/knode-arch.png b/docs/images/clustertree-arch.png similarity index 100% rename from docs/images/knode-arch.png rename to docs/images/clustertree-arch.png