fix(tiller): ignore empty YAML documents during delete

Closes #2256
pull/2268/head
Matt Butcher 8 years ago
parent bc8b3bb17d
commit 573a8a190c
No known key found for this signature in database
GPG Key ID: DCD5F5E5EF32C345

@ -1058,7 +1058,10 @@ func (s *ReleaseServer) UninstallRelease(c ctx.Context, req *services.UninstallR
// Collect the errors, and return them later.
es := []string{}
for _, file := range filesToDelete {
b := bytes.NewBufferString(file.content)
b := bytes.NewBufferString(strings.TrimSpace(file.content))
if b.Len() == 0 {
continue
}
if err := s.env.KubeClient.Delete(rel.Namespace, b); err != nil {
log.Printf("uninstall: Failed deletion of %q: %s", req.Name, err)
if err == kube.ErrNoObjectsVisited {

Loading…
Cancel
Save