[Dnsmasq-discuss] server-side dynamic resolving
Chris Wilson
chris+dnsmasq at aptivate.org
Sun Aug 12 11:05:03 BST 2012
Hi Travis,
On Sat, 11 Aug 2012, Travis Hansen wrote:
> I'm attempting to integrate dnsmasq with mdns. I'm not really sure
> how to go about it but I'll explain the scenario...
>
> 1. My machine is known as '15z' and via mdns clients resolves as 15z.local
> 2. I have apache running mod_dnssd (not actually critical to the
> situation but gives context at least) with a virtual host
> 15z.foobar.dev
> 3. I'd like to make it so 15z.foobar.dev gets returned by dnsmasq as
> whatever the current value of 15z.local is (the server is running
> avahi).
>
> Anyone have any great suggestions for me? I've thought about
> combinations of entering cname records into dnsmasq and somehow trying
> to integrate that but ultimately
Do you control the DNS for the foobar.dev zone, and is it hosted by a full DNS
server (not dnsmasq)? If so, just put a CNAME in the zone file:
15z IN CNAME 15z.local.
If not, and 15z registers itself with the dnsmasq DHCP server, then you can
bypass ahavi/mdns and just CNAME 15z.foobar.dev to the machine 15z in dnsmasq
config:
cname=15z.foobar.dev,15z
> I couldn't get dnsmasq to return what the local *server* resolves a given name
> too (limited to just hosts/dhcp/upstream dns).
You probably can't do that without programming, so I suggest you find other ways
to achieve what you want first, such as CNAME.
> I'd rather not run stuff client side.
With a CNAME you don't need to run anything other than a standard resolver on
the client side, which most likely you already do.
Cheers, Chris.
--
Aptivate | http://www.aptivate.org | Phone: +44 1223 967 838
Future Business, Cam City FC, Milton Rd, Cambridge, CB4 1UY, UK
Aptivate is a not-for-profit company registered in England and Wales
with company number 04980791.
More information about the Dnsmasq-discuss
mailing list