mesh icon indicating copy to clipboard operation
mesh copied to clipboard

Support CoreDNS daemonsets, too

Open der-eismann opened this issue 5 years ago • 2 comments

Feature Request

Proposal

I'd like traefik mesh to also support CoreDNS when used as a daemonset instead of a deployment.

Background

We use one dns pod per worker to achieve a lower latency, however in the code it explicitly looks for a deployment which must be named coredns. A bit more flexibility on that part would be great.

Workarounds

None that I know of.

der-eismann avatar Nov 09 '20 16:11 der-eismann

Similarly, if you deploy coredns via a helm chart, you end up with a deployment named something like coredns-coredns (or RELEASE-NAME-coredns). This also bypasses the check here, and so makes traefik-mesh not functional.

https://github.com/traefik/mesh/blob/e53767daee443f55338a4ffcf07e66b39afb630f/pkg/dns/client.go#L85

Further, it makes mitigating #787 require deploying coredns directly (i.e. not using helm)

https://github.com/coredns/helm/blob/3bac534c105e6b72e74ea5d9e829b47159b284ff/stable/coredns/templates/_helpers.tpl#L18

Maybe at a minimum making this configurable via an env var / etc. (and then exposing as a value in your helm chart) would give us a workaround to point at deployments / deamonsets, other names, etc.

colearendt avatar Jan 28 '21 06:01 colearendt

Is there anyway to bypass this check ? I am on a managed kubernetes cluster and the image name tag used for coredns deployment is a custom tag without containing exact version string that code is looking for parts := strings.Split(container.Image, ":") Would it be possible to provide a way to consciously avoid this check is such cases ?

spurti-chopra avatar Feb 06 '21 19:02 spurti-chopra

Closing because it's been 2 years now and we don't use this anyway

der-eismann avatar Dec 16 '22 10:12 der-eismann