如何在两个Kubernetes集群之间建立联盟?

时间:2020-01-24 12:37:23

标签: kubernetes

我想在集群之间建立联合,但是由于Kubernetes网站和联合回购文档的文档存在差异,我有些困惑。

website上提到“强烈建议不要使用联盟v1。”但他们自己的link指向的是v1版本(v1.10.0-alpha.0,v1.9.0-alpha.3,v1.9.0-beta.0),并且最新版本已有2年的历史:

v1.10.0-alpha.0:

federation-client-linux-amd64.tar.gz    11.47 MB    application/x-tar   Standard    2/20/18, 8:44:21 AM UTC+1   
federation-client-linux-amd64.tar.gz.sha    103 B   application/octet-stream    Standard    2/20/18, 8:44:20 AM UTC+1   
federation-server-linux-amd64.tar.gz    131.05 MB   application/x-tar   Standard    2/20/18, 8:44:23 AM UTC+1   
federation-server-linux-amd64.tar.gz.sha    103 B   application/octet-stream    Standard    2/20/18, 8:44:20 AM UTC+1

另一方面,我按照installation上的说明进行了操作,并安装了kubefedctl-0.1.0-rc6-linux-amd64.tgz,但是它没有Kubernetes官方网站中提到的任何init命令。 Kubernetes网站:

kubefed init fellowship \
    --host-cluster-context=rivendell \
    --dns-provider="google-clouddns" \
    --dns-zone-name="example.com."

最新版本kubefedctl帮助:

$kubefedctl -h

kubefedctl controls a Kubernetes Cluster Federation. Find more information at https://sigs.k8s.io/kubefed.

Usage:
  kubefedctl [flags]
  kubefedctl [command]

Available Commands:
  disable            Disables propagation of a Kubernetes API type
  enable             Enables propagation of a Kubernetes API type
  federate           Federate creates a federated resource from a kubernetes resource
  help               Help about any command
  join               Register a cluster with a KubeFed control plane
  orphaning-deletion Manage orphaning delete policy
  unjoin             Remove the registration of a cluster from a KubeFed control plane
  version            Print the version info

Flags:
      --alsologtostderr                  log to standard error as well as files
  -h, --help                             help for kubefedctl
      --log-backtrace-at traceLocation   when logging hits line file:N, emit a stack trace (default :0)
      --log-dir string                   If non-empty, write log files in this directory
      --log-file string                  If non-empty, use this log file
      --log-flush-frequency duration     Maximum number of seconds between log flushes (default 5s)
      --logtostderr                      log to standard error instead of files (default true)
      --skip-headers                     If true, avoid header prefixes in the log messages
      --stderrthreshold severity         logs at or above this threshold go to stderr
  -v, --v Level                          number for the log level verbosity
      --vmodule moduleSpec               comma-separated list of pattern=N settings for file-filtered logging

Use "kubefedctl [command] --help" for more information about a command.

然后是helm chart,其中说:“它建立在Federation v1的同步控制器(又名推送协调器)的基础上,以迭代集思广益文档中提出的API概念,并在体系结构文档中进一步完善。 ”因此,如果我没记错的话,则表示舵图基于DeprecatedFederation v1

此外,回购中的userguid在这种情况下没有帮助。它显示了如何“启用Kubernetes API类型的传播”,但没有设置主机群集(等于kubefed init)。

有人可以让我知道如何在裸机上建立一个联合的多集群Kubernetes并加入另一个集群吗?

0 个答案:

没有答案
相关问题