From 70f80c8cc1c399f0fe31d2341bcc6d1ee6445c5b Mon Sep 17 00:00:00 2001 From: Titouan Bion Date: Fri, 15 May 2020 16:02:13 +0200 Subject: [PATCH] docs: adding documentation to add an array element using overrides Related to https://github.com/kubernetes-sigs/kubefed/issues/1224 Adding a value to an array could be confusing for users, an example in the docs could alleviate the confusion. --- docs/userguide.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/userguide.md b/docs/userguide.md index 69869c5408..4968f35a0e 100644 --- a/docs/userguide.md +++ b/docs/userguide.md @@ -688,6 +688,11 @@ spec: # Ensure an annotation with key "foo" does not exist - path: "/metadata/annotations/foo" op: "remove" + # Adds an argument `-q` at index 0 of the args list + # this will obviously shift the existing arguments, if any + - path: "/spec/template/spec/containers/0/args/0" + op: "add" + value: "-q" ``` ### Overriding retained fields