diff --git a/pkg/deploy/controller.go b/pkg/deploy/controller.go index 1bf7dad2d5..6061c92cc2 100644 --- a/pkg/deploy/controller.go +++ b/pkg/deploy/controller.go @@ -254,8 +254,9 @@ func checksum(bytes []byte) string { func isEmptyYaml(yaml []byte) bool { isEmpty := true lines := bytes.Split(yaml, []byte("\n")) - for _, k := range lines { - if string(k) != "---" && !bytes.HasPrefix(k, []byte("#")) && string(k) != "" { + for _, l := range lines { + s := bytes.TrimSpace(l) + if string(s) != "---" && !bytes.HasPrefix(s, []byte("#")) && string(s) != "" { isEmpty = false } }