diff --git a/pkg/skaffold/deploy/labels.go b/pkg/skaffold/deploy/labels.go index c832f45d034..d7539be8515 100644 --- a/pkg/skaffold/deploy/labels.go +++ b/pkg/skaffold/deploy/labels.go @@ -140,7 +140,7 @@ func updateRuntimeObject(client dynamic.Interface, disco discovery.DiscoveryInte return errors.Wrap(err, "getting metadata accessor") } name := accessor.GetName() - namespace := accessor.GetNamespace() + namespace := res.Namespace addLabels(labels, accessor) modifiedJSON, _ := json.Marshal(modifiedObj)