|
|
@ -428,9 +428,7 @@ func updateResource(c *Client, target *resource.Info, currentObj runtime.Object,
|
|
|
|
if err := target.Get(); err != nil {
|
|
|
|
if err := target.Get(); err != nil {
|
|
|
|
return fmt.Errorf("error trying to refresh resource information: %v", err)
|
|
|
|
return fmt.Errorf("error trying to refresh resource information: %v", err)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return nil
|
|
|
|
} else {
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// send patch to server
|
|
|
|
// send patch to server
|
|
|
|
helper := resource.NewHelper(target.Client, target.Mapping)
|
|
|
|
helper := resource.NewHelper(target.Client, target.Mapping)
|
|
|
|
|
|
|
|
|
|
|
@ -463,6 +461,7 @@ func updateResource(c *Client, target *resource.Info, currentObj runtime.Object,
|
|
|
|
// When patch succeeds without needing to recreate, refresh target.
|
|
|
|
// When patch succeeds without needing to recreate, refresh target.
|
|
|
|
target.Refresh(obj, true)
|
|
|
|
target.Refresh(obj, true)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if !recreate {
|
|
|
|
if !recreate {
|
|
|
|
return nil
|
|
|
|
return nil
|
|
|
|