<p>How should my rule look like : 
if want to support dynamic url mapping to services</p>

<pre><code>/a should map to service service-a
/b should map to service service-b
/cccc should map to service service-cccc

</code></pre>

<p>Note : services can be added dynamically </p>

<p>hence afte r say 10 minutes. we now have </p>

<pre><code>/dddd should map to service service-dddd

</code></pre>

shrw
<p>Basically you keep appending new path to $.spec.rules[x].http.paths, where x is the index of the host which you intend to add path on.</p>

<pre><code>apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: my-ingress
  namespace: my-namespace
  annotations:
    kubernetes.io/ingress.class: "nginx"
    # and other annotations you need..
  #labels:
     # if you need labels
spec:
  rules:
  - host: "your.hostname"
    http:
      paths:
      - path: /a
        backend:
          serviceName: service-a
          servicePort: 443 # say your service runs on 443
      - path: /b
        backend:
          serviceName: service-b
          servicePort: 443 # say your service runs on 443
      - path: /cccc
        backend:
          serviceName: service-cccc
          servicePort: 443 # say your service runs on 443
</code></pre>
