mirror of https://github.com/kubernetes/kops.git
Add test case for node labels and taints
This commit is contained in:
parent
eb6bc8544a
commit
804d6a6065
|
@ -45,6 +45,7 @@ KubeletConfig:
|
||||||
kubeconfigPath: /var/lib/kubelet/kubeconfig
|
kubeconfigPath: /var/lib/kubelet/kubeconfig
|
||||||
logLevel: 2
|
logLevel: 2
|
||||||
nodeLabels:
|
nodeLabels:
|
||||||
|
kops.k8s.io/instancegroup: nodes
|
||||||
node-role.kubernetes.io/node: ""
|
node-role.kubernetes.io/node: ""
|
||||||
podInfraContainerImage: registry.k8s.io/pause:3.9
|
podInfraContainerImage: registry.k8s.io/pause:3.9
|
||||||
podManifestPath: /etc/kubernetes/manifests
|
podManifestPath: /etc/kubernetes/manifests
|
||||||
|
@ -52,6 +53,8 @@ KubeletConfig:
|
||||||
registerSchedulable: true
|
registerSchedulable: true
|
||||||
shutdownGracePeriod: 30s
|
shutdownGracePeriod: 30s
|
||||||
shutdownGracePeriodCriticalPods: 10s
|
shutdownGracePeriodCriticalPods: 10s
|
||||||
|
taints:
|
||||||
|
- a=b:c
|
||||||
KubernetesVersion: 1.32.0
|
KubernetesVersion: 1.32.0
|
||||||
Networking:
|
Networking:
|
||||||
nonMasqueradeCIDR: 100.64.0.0/10
|
nonMasqueradeCIDR: 100.64.0.0/10
|
||||||
|
|
|
@ -152,7 +152,7 @@ ConfigServer:
|
||||||
- https://kops-controller.internal.ha-gce.example.com:3988/
|
- https://kops-controller.internal.ha-gce.example.com:3988/
|
||||||
InstanceGroupName: nodes
|
InstanceGroupName: nodes
|
||||||
InstanceGroupRole: Node
|
InstanceGroupRole: Node
|
||||||
NodeupConfigHash: yKU09Zx4MJaCy5r784FI8CXqrVXqnDp7nZdOuzohYlU=
|
NodeupConfigHash: RTYXnI1xkrWZ/Bnir7cCMFBfUMzhd6uvrj0Zkdg5Z7o=
|
||||||
|
|
||||||
__EOF_KUBE_ENV
|
__EOF_KUBE_ENV
|
||||||
|
|
||||||
|
|
|
@ -132,9 +132,13 @@ spec:
|
||||||
machineType: e2-medium
|
machineType: e2-medium
|
||||||
maxSize: 2
|
maxSize: 2
|
||||||
minSize: 2
|
minSize: 2
|
||||||
|
nodeLabels:
|
||||||
|
kops.k8s.io/instancegroup: nodes
|
||||||
role: Node
|
role: Node
|
||||||
subnets:
|
subnets:
|
||||||
- us-test1
|
- us-test1
|
||||||
|
taints:
|
||||||
|
- a=b:c
|
||||||
zones:
|
zones:
|
||||||
- us-test1-a
|
- us-test1-a
|
||||||
- us-test1-b
|
- us-test1-b
|
||||||
|
|
|
@ -741,7 +741,7 @@ resource "google_compute_instance_template" "nodes-ha-gce-example-com" {
|
||||||
metadata = {
|
metadata = {
|
||||||
"cluster-name" = "ha-gce.example.com"
|
"cluster-name" = "ha-gce.example.com"
|
||||||
"kops-k8s-io-instance-group-name" = "nodes"
|
"kops-k8s-io-instance-group-name" = "nodes"
|
||||||
"kube-env" = "AUTOSCALER_ENV_VARS: os_distribution=ubuntu;arch=amd64;os=linux"
|
"kube-env" = "AUTOSCALER_ENV_VARS: os_distribution=ubuntu;arch=amd64;os=linux;node_labels=kops.k8s.io/instancegroup=nodes;node_taints=a=b:c"
|
||||||
"ssh-keys" = "admin: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAAgQCtWu40XQo8dczLsCq0OWV+hxm9uV3WxeH9Kgh4sMzQxNtoU1pvW0XdjpkBesRKGoolfWeCLXWxpyQb1IaiMkKoz7MdhQ/6UKjMjP66aFWWp3pwD0uj0HuJ7tq4gKHKRYGTaZIRWpzUiANBrjugVgA+Sd7E/mYwc/DMXkIyRZbvhQ=="
|
"ssh-keys" = "admin: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAAgQCtWu40XQo8dczLsCq0OWV+hxm9uV3WxeH9Kgh4sMzQxNtoU1pvW0XdjpkBesRKGoolfWeCLXWxpyQb1IaiMkKoz7MdhQ/6UKjMjP66aFWWp3pwD0uj0HuJ7tq4gKHKRYGTaZIRWpzUiANBrjugVgA+Sd7E/mYwc/DMXkIyRZbvhQ=="
|
||||||
"user-data" = file("${path.module}/data/google_compute_instance_template_nodes-ha-gce-example-com_metadata_user-data")
|
"user-data" = file("${path.module}/data/google_compute_instance_template_nodes-ha-gce-example-com_metadata_user-data")
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue