platform9 / cctl

Apache License 2.0
47 stars 8 forks source link

Identify Node to be drained/deleted using reference in Machine object #63

Open dlipovetsky opened 6 years ago

dlipovetsky commented 6 years ago

Right now the node is identified by invoking hostname -f on the host, but this only works coincidentally. Once https://github.com/platform9/ssh-provider/issues/17 is fixed, use the Node reference.

dlipovetsky commented 6 years ago

Every node must have a unique MAC and product ID [0].

[0] https://kubernetes.io/docs/setup/independent/install-kubeadm/#verify-the-mac-address-and-product-uuid-are-unique-for-every-node

dlipovetsky commented 6 years ago

https://stackoverflow.com/questions/35008011/kubernetes-how-do-i-know-what-node-im-on/42884562

dlipovetsky commented 6 years ago

See https://github.com/kubernetes-sigs/cluster-api/blob/a7e3b5ab5a9cbfdbc5288e03df92f0e862c292d9/pkg/controller/machine/node.go.