本文為英文版的機器翻譯版本,如內容有任何歧義或不一致之處,概以英文版為準。
非 eksctl 建立的叢集
您可以針對 未建立的叢集執行eksctl命令eksctl。
注意
Eksctl 只能支援名稱與 AWS CloudFormation 相容的未擁有叢集。任何不相符的叢集名稱都會失敗 CloudFormation API 驗證檢查。
支援的命令
下列命令可用於透過 以外的任何方式建立的叢集eksctl。命令、旗標和組態檔案選項的使用方式完全相同。
如果我們遺漏了一些功能,請讓我們知道
-
✓ 建立:
-
✓
eksctl create nodegroup(請參閱以下備註) -
✓
eksctl create fargateprofile -
✓
eksctl create iamserviceaccount -
✓
eksctl create iamidentitymapping
-
-
✓ 取得:
-
✓
eksctl get clusters/cluster -
✓
eksctl get fargateprofile -
✓
eksctl get nodegroup -
✓
eksctl get labels
-
-
✓ 刪除:
-
✓
eksctl delete cluster -
✓
eksctl delete nodegroup -
✓
eksctl delete fargateprofile -
✓
eksctl delete iamserviceaccount -
✓
eksctl delete iamidentitymapping
-
-
✓ 升級:
-
✓
eksctl upgrade cluster -
✓
eksctl upgrade nodegroup
-
-
✓ 設定/取消設定:
-
✓
eksctl set labels -
✓
eksctl unset labels
-
-
✓ 擴展:
-
✓
eksctl scale nodegroup
-
-
✓ 耗盡:
-
✓
eksctl drain nodegroup
-
-
✓ 啟用:
-
✓
eksctl enable profile -
✓
eksctl enable repo
-
-
✓ Utils:
-
✓
eksctl utils associate-iam-oidc-provider -
✓
eksctl utils describe-stacks -
✓
eksctl utils install-vpc-controllers -
✓
eksctl utils nodegroup-health -
✓
eksctl utils set-public-access-cidrs -
✓
eksctl utils update-cluster-endpoints -
✓
eksctl utils update-cluster-logging -
✓
eksctl utils write-kubeconfig -
✓
eksctl utils update-coredns -
✓
eksctl utils update-aws-node -
✓
eksctl utils update-kube-proxy
-
建立節點群組
eksctl create nodegroup 是唯一需要使用者特定輸入的命令。
由於使用者可以使用他們喜歡的任何聯網組態建立叢集,因此在時間範圍內, eksctl 不會嘗試擷取或猜測這些值。隨著我們進一步了解人們如何在非 eksctl 建立的叢集上使用此命令,這可能會在未來變更。
這表示為了在非由 建立的叢集上建立節點群組或受管節點群組eksctl,必須提供包含 VPC 詳細資訊的組態檔案。至少:
--- apiVersion: eksctl.io/v1alpha5 kind: ClusterConfig metadata: name: non-eksctl-created-cluster region: us-west-2 vpc: id: "vpc-12345" securityGroup: "sg-12345" # this is the ControlPlaneSecurityGroup subnets: private: private1: id: "subnet-12345" private2: id: "subnet-67890" public: public1: id: "subnet-12345" public2: id: "subnet-67890" ...
如需 VPC 組態選項的詳細資訊,請參閱聯網。