mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-13 13:14:05 +00:00
don't try to remove the node if kubeconfig doesn't exist
This commit is contained in:
committed by
George Kraft
parent
258ee22858
commit
6e831d6fe9
@@ -152,7 +152,8 @@ def shutdown():
|
||||
- stop the kube-proxy service
|
||||
- remove the 'kubernetes-worker.cni-plugins.installed' state
|
||||
'''
|
||||
kubectl('delete', 'node', gethostname())
|
||||
if os.path.isfile(kubeconfig_path):
|
||||
kubectl('delete', 'node', gethostname())
|
||||
service_stop('kubelet')
|
||||
service_stop('kube-proxy')
|
||||
remove_state('kubernetes-worker.cni-plugins.installed')
|
||||
|
Reference in New Issue
Block a user