add check that kustomization is empty

This commit is contained in:
koba1t
2022-12-28 21:16:32 +09:00
parent d3184da4c6
commit 2c2b2ab825
5 changed files with 88 additions and 10 deletions

View File

@@ -73,6 +73,11 @@ func (kt *KustTarget) Load() error {
k.FixKustomization()
// check that Kustomization is empty
if err := k.CheckEmpty(); err != nil {
return err
}
errs := k.EnforceFields()
if len(errs) > 0 {
return fmt.Errorf(