We have a site to site VPN connection setup in the office to two development networks
- dev
- stage
I want to be able to let people in the office not be on VPN for dns resolution to work. Each environment also has its own dns server. So I can't give the whole office a single dns server via dhcp and call it a day.
I tried the following
echo 'nameserver 10.122.3.10' > /etc/resolver/dev.domain.com
echo 'nameserver 10.121.3.10' > /etc/resolver/stage.domain.com
the OS seems to be picking it up
ip-10-1-1-116:~ username$ scutil --dns
DNS configuration
resolver #1
search domain[0] : google.com
nameserver[0] : 8.8.8.8
nameserver[1] : 8.8.4.4
if_index : 4 (en0)
flags : Request A records
reach : Reachable
resolver #2
domain : stage.domain.com
nameserver[0] : 10.121.3.10
flags : Request A records
reach : Reachable
DNS configuration (for scoped queries)
resolver #1
search domain[0] : google.com
nameserver[0] : 8.8.8.8
nameserver[1] : 8.8.4.4
if_index : 4 (en0)
flags : Scoped, Request A records
reach : Reachable
The issue is I can't resolve anything on the stage.domain.com domain search
ip-10-1-1-116:resolver username$ nslookup mongo-arb.stage.domain.com
Server: 8.8.8.8
Address: 8.8.8.8#53
** server can't find mongo-arb.stage.domain.com: NXDOMAIN
I can hit it going right to the server
ip-10-1-1-116:resolver username$ nslookup mongo-arb.stage.domain.com 10.121.3.10
Server: 10.121.3.10
Address: 10.121.3.10#53
Non-authoritative answer:
Name: mongo-arb.stage.domain.com
Address: 10.121.15.116
EDIT
I'm using 10.10.4