AdguardTeam / AdguardTeam/AdGuardHome
create a way to use default host's resolver
- Ngôn ngữ chính
- TypeScript
- Star
- 36.9k
- Fork
- 2.5k
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
### 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.
Hướng dẫn đóng góp
Đánh giá
Issue này chưa được đánh giá.