mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 11:50:44 +00:00
Skip errors when unregistering juju kubernetes-workers
This commit is contained in:
parent
bce32b66cd
commit
90a57931af
@ -160,8 +160,11 @@ def shutdown():
|
||||
- delete the current node
|
||||
- stop the worker services
|
||||
'''
|
||||
if os.path.isfile(kubeconfig_path):
|
||||
kubectl('delete', 'node', gethostname())
|
||||
try:
|
||||
if os.path.isfile(kubeconfig_path):
|
||||
kubectl('delete', 'node', gethostname())
|
||||
except CalledProcessError:
|
||||
hookenv.log('Failed to unregister node.')
|
||||
service_stop('snap.kubelet.daemon')
|
||||
service_stop('snap.kube-proxy.daemon')
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user