Kops 创建实例组
kops 创建实例组 ¶
创建一个实例组。
概要 ¶
创建一个实例组配置。
实例组是相似虚拟机的集合。在 AWS 上,实例组映射到一个自动扩展组。
实例组的角色定义了机器将充当 Kubernetes 控制平面还是工作节点。
kops create instancegroup INSTANCE_GROUP [flags]
示例 ¶
# Create an instancegroup for the k8s-cluster.example.com cluster.
kops create instancegroup --name=k8s-cluster.example.com node-example \
--role node --subnet my-subnet-name,my-other-subnet-name
# Create a YAML manifest for an instancegroup for the k8s-cluster.example.com cluster.
kops create instancegroup --name=k8s-cluster.example.com node-example \
--role node --subnet my-subnet-name --dry-run -oyaml
选项 ¶
--dry-run Only print the object that would be created, without created it. This flag can be used to create an instance group YAML or JSON manifest.
--edit Open an editor to edit default values (default true)
-h, --help help for instancegroup
-o, --output string Output format. One of json or yaml
--role string Type of instance group to create (control-plane,node,bastion) (default "node")
--subnet strings Subnet in which to create instance group. One of Availability Zone like eu-west-1a or a comma-separated list of multiple Availability Zones.
从父命令继承的选项 ¶
--config string yaml config file (default is $HOME/.kops.yaml)
--name string Name of cluster. Overrides KOPS_CLUSTER_NAME environment variable
--state string Location of state storage (kops 'config' file). Overrides KOPS_STATE_STORE environment variable
-v, --v Level number for the log level verbosity
另请参阅 ¶
- kops create - 通过命令行、文件名或标准输入创建资源。