kubernetes-ingress icon indicating copy to clipboard operation
kubernetes-ingress copied to clipboard

Allow specification of the `target` or `targets` in a `VirtualServer`'s `externalDNS` properties

Open j1m-ryan opened this issue 1 year ago • 6 comments

Is your feature request related to a problem? Please describe. My problem is that the external ip address of my ingress controller, is not one that is accessible via the internet. It is a local ip address, which is then exposed to the internet via DMZ.

NIC chooses its external IP address (or addresses) when setting the DNSEndpoint entries, however I would like to overwite the target attribute. You can choose other aspects of a DNSEndpoint in the virtualserver so it would be ideal to be able to choose the target or targets here also

Describe the solution you'd like In the externalDNS struct in the virtualservers

externalDNS:
    enable: true
    target: 1.2.3.4 # Set public ip

Alternatively this

externalDNS:
    enable: true
    targets:
      - 1.2.3.4 # setting multiple targets
      - 5.6.7.8

I do not myself have a usecase for setting multiple targets so would be happy with one.

Describe alternatives you've considered Using an ingress instead with an externaldns annotation which allows setting the target. This does work for me but I would much prefer to use VirtualServers

annotations: # on the ingress resource
    external-dns.alpha.kubernetes.io/target: "1.2.3.4"

Additional context external-dns.alpha.kubernetes.io/target takes a comma separated list of targets so maybe this is sensible to follow, and have a list rather than a single target.

j1m-ryan avatar Mar 05 '24 08:03 j1m-ryan

I am also very interested in this. right now we use custom targets which is a must to use VirtualServer instead of ingress. @j1m-ryan is there any plans to implement this ? and is there any workaround and still keep using VirtualServer ? Thanks a lot!

sov-msaeed avatar Dec 09 '24 13:12 sov-msaeed

Hi @sov-msaeed, no this has not been prioritised yet. Will tag @shaun-nx to have a look

j1m-ryan avatar Dec 10 '24 09:12 j1m-ryan

Thanks a lot ! right now the only workaround i found is not to enable externalDns from the Virtualserver definition at all. and I Create the DNSEndpoint manually.

sov-msaeed avatar Dec 10 '24 09:12 sov-msaeed

@j1m-ryan Do you have any update on the pull request ?

sov-msaeed avatar Mar 26 '25 07:03 sov-msaeed

@vepatel maybe you have any update on that as @j1m-ryan is not responding, this is very important for us as it will save us creation of hundreds of DNSEndpoints manually.

sov-msaeed avatar Apr 08 '25 13:04 sov-msaeed

Hey @sov-msaeed, unfortunately I can't comment on timeline for this enhancement but we will definitely be reviewing attached PR.

vepatel avatar Jun 13 '25 09:06 vepatel