mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 11:21:47 +00:00
Merge pull request #81958 from apelisse/ssa-improve-conflict-error
Improve error message on server-side apply conflicts
This commit is contained in:
commit
f0c600d15a
@ -418,7 +418,22 @@ func (o *ApplyOptions) Run() error {
|
||||
if isIncompatibleServerError(err) {
|
||||
err = fmt.Errorf("Server-side apply not available on the server: (%v)", err)
|
||||
}
|
||||
if errors.IsConflict(err) {
|
||||
err = fmt.Errorf(`%v
|
||||
|
||||
Please review the fields above--they currently have other managers. Here
|
||||
are the ways you can resolve this warning:
|
||||
* If you intend to manage all of these fields, please re-run the apply
|
||||
command with the `+"`--force-conflicts`"+` flag.
|
||||
* If you do not intend to manage all of the fields, please edit your
|
||||
manifest to remove references to the fields that should keep their
|
||||
current managers.
|
||||
* You may co-own fields by updating your manifest to match the existing
|
||||
value; in this case, you'll become the manager if the other manager(s)
|
||||
stop managing the field (remove it from their configuration).
|
||||
|
||||
See http://k8s.io/docs/reference/using-api/api-concepts/#conflicts`, err)
|
||||
}
|
||||
return err
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user