Add item to list in yq if it doesn't already exist
Using mikefarah’s yq v4 I want to conditionally add an IP address to a list within a yml file if it does not exist in the list already. Given a file like: servers: web: – 1.1.1.1 jobs: – 2.2.2.2 If 1.1.1.1 was attempted to be added it should not change, if 3.3.3.3 was added to… Read More Add item to list in yq if it doesn't already exist