How to handle services when the developers provide incorrectly in k8s
@Mkash, don't you know in advance what services you have in your services.yaml file?
Maintain a list in groovy, and see whether the input is in that list or not.
Something like:
availableServices = [&quot;ew_ws_gateway&quot;, &quot;ingress&quot;]

services = [&quot;a&quot;, &quot;b&quot;, &quot;c&quot;, &quot;ew_ws_gateway&quot;]

services.each { svc -&gt;
    if (svc in availableServices) {
        println(&quot;Service exist&quot; + svc)
    }
}

The other option is to change the parameter from type of text to multiple-choice possibly using https://plugins.jenkins.io/extended-choice-parameter/