AdguardTeam / AdguardTeam/AdGuardHome

create a way to use default host's resolver

Offen
#8,326 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
feature request
Vorherrschende Sprache
TypeScript
Sterne
36.9k
Forks
2.5k
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

### Prerequisites

- [x] I have checked the [Wiki](https://github.com/AdguardTeam/AdGuardHome/wiki) and [Discussions](https://github.com/AdguardTeam/AdGuardHome/discussions) and found no answer

- [x] I have searched other issues and found no duplicates

- [x] I want to request a feature or enhancement and not ask a question

### The problem

I am running AdGuardHome on Kubernetes and I want to use the specific domains with custom upstream. My custom upstream is another DNS server deployed in the same cluster, there I have my internal zones.

The problem is that I, obviously, want to address that DNS upstream by its hostname, which is a Kubernetes DNS name (service.namespace.svc.cluster.local). Which is resolved by the cluster's own DNS server (CoreDNS).

Using cluster's DNS IP address in AdGuardHome configuration is not a good idea as the cluster itself controls it. Yes, it is stable indeed, but changes from one cluster to another, of course.

This is my specific domain config:
```
[/iot.internal/]coredns.coredns-private.svc.cluster.local:53
```
(I use a dedicated deployment of CoreDNS for it, not the cluster's one)

But only the cluster's CoreDNS knows how to resolve that "coredns.coredns-private.svc.cluster.local". And there is no way to use it.

### Proposed solution

Probably, the most elegant option, unless I am missing something, would be to have another upstream config type - the one that uses the default host's (pod's in this case) resolver? Then for Kubernetes deployments, it would be like:

```
[/*.svc.cluster.local/]
```

### Alternatives considered and additional information

At this point, it seems I will have no choice but to use my init container to extract the IP address from /etc/resolv.conf and populate bootstrap_dns value using it.

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.