def delete(self, name):
"""Delete the named resource.
TODO: should be easy to rewrite this as a kube api
delete call instead of going through kubectl.
"""
try:
self.kubectl.delete(
self.url_type,
name,
'--context={}'.format(self.config.context),
'--namespace={}'.format(self.config.namespace)
)
except sh.ErrorReturnCode as err:
logging.error("Unexpected response: %s", err)
评论列表
文章目录