update kubectl subcommand with -k changes

This commit is contained in:
Jingfang Liu
2019-02-25 16:30:50 -08:00
parent 0c026bfac1
commit b38cf738d6
18 changed files with 47 additions and 22 deletions

View File

@@ -198,7 +198,7 @@ func (o *SetImageOptions) Validate() error {
if o.All && len(o.Selector) > 0 {
errors = append(errors, fmt.Errorf("cannot set --all and --selector at the same time"))
}
if len(o.Resources) < 1 && cmdutil.IsFilenameSliceEmpty(o.Filenames) {
if len(o.Resources) < 1 && cmdutil.IsFilenameSliceEmpty(o.Filenames, o.Kustomize) {
errors = append(errors, fmt.Errorf("one or more resources must be specified as <resource> <name> or <resource>/<name>"))
}
if len(o.ContainerImages) < 1 {