Just tried to set up a wildcard DNS on Snow Leopard according to these instructions:
http://geoffhankerson.com/node/108
But I couldn't get it to work, and I think even if it did, it doesn't do what I need it to anyway.
Basically, I'm running Ubuntu in a VM in Snow Leopard, so I can have a local 'hack environment. It works, but I need to add an entry in my hosts file for each new test user I create (inconvenient, but a minor annoyance). The bigger problem is that every time I put my laptop to sleep, the internal IP changes when it wakes up, so I need to edit the hosts file again (sometimes I forget to, and I end up staring at a blank screen, wondering if I've borked my dev env :-()
Anyway, no big loss with not being able to set up wildcard DNS. From what I understand now, setting up my own DNS server would have fixed the first problem (which I only need to deal with occasionally) but not the second (which I have to deal with every time I start up my server).
I don't want to just set up the wildcard DNS under my website (afunamatata.com) because I wanted it to work when I'm not connected to the internet, and it still doesn't solve the second problem with the shifting IP address, so I'd need to open up the browser, log on, and edit the IP address online (then wait for the DNS cache to flush?) before any work session. UGH.
I can always access my VM under its .local address, but I can't find a way to redirect all *.dream.fu traffic to .local. All the solutions I've thought of so far seem worse than the original problem! So I guess it's put up and just deal with editing my hosts file all the time.
If I can't think of a better way, I wonder if I could just set up a script which looks up the current IP address of my hosts file, and then use sed or awk to replace the IP address in my hosts file (parse the output of traceroute? dig, nslookup, host don't work).
Soooo right now I don't think I know enough to do what I want, or to even know if it's possible to do what I want, but I think I know enough by now to confirm that the above won't do what I need it to, so okay.
ETA:
Ah an now the obvious answer for #2 hits me: set Ubuntu to use a static IP, so that the IP address stays constant, even after going to sleep/waking up (Not so obvious bits: finding out what the IP address of the router is, since it's something VMWare set, not something I did, but I found it using the route command on Ubuntu).
I don't know if I did it right. I thought I'd set this to a static IP before, but I guess I did something wrong (I don't remember doing it this way, either *g*). Hopefully I've got it figured out this time.
http://geoffhankerson.com/node/108
But I couldn't get it to work, and I think even if it did, it doesn't do what I need it to anyway.
Basically, I'm running Ubuntu in a VM in Snow Leopard, so I can have a local 'hack environment. It works, but I need to add an entry in my hosts file for each new test user I create (inconvenient, but a minor annoyance). The bigger problem is that every time I put my laptop to sleep, the internal IP changes when it wakes up, so I need to edit the hosts file again (sometimes I forget to, and I end up staring at a blank screen, wondering if I've borked my dev env :-()
Anyway, no big loss with not being able to set up wildcard DNS. From what I understand now, setting up my own DNS server would have fixed the first problem (which I only need to deal with occasionally) but not the second (which I have to deal with every time I start up my server).
I don't want to just set up the wildcard DNS under my website (afunamatata.com) because I wanted it to work when I'm not connected to the internet, and it still doesn't solve the second problem with the shifting IP address, so I'd need to open up the browser, log on, and edit the IP address online (then wait for the DNS cache to flush?) before any work session. UGH.
I can always access my VM under its .local address, but I can't find a way to redirect all *.dream.fu traffic to .local. All the solutions I've thought of so far seem worse than the original problem! So I guess it's put up and just deal with editing my hosts file all the time.
If I can't think of a better way, I wonder if I could just set up a script which looks up the current IP address of my hosts file, and then use sed or awk to replace the IP address in my hosts file (parse the output of traceroute? dig, nslookup, host don't work).
Soooo right now I don't think I know enough to do what I want, or to even know if it's possible to do what I want, but I think I know enough by now to confirm that the above won't do what I need it to, so okay.
ETA:
Ah an now the obvious answer for #2 hits me: set Ubuntu to use a static IP, so that the IP address stays constant, even after going to sleep/waking up (Not so obvious bits: finding out what the IP address of the router is, since it's something VMWare set, not something I did, but I found it using the route command on Ubuntu).
I don't know if I did it right. I thought I'd set this to a static IP before, but I guess I did something wrong (I don't remember doing it this way, either *g*). Hopefully I've got it figured out this time.
no subject
Date: 2010-04-05 03:58 am (UTC)no subject
Date: 2010-04-05 04:06 am (UTC)no subject
Date: 2010-04-05 05:08 am (UTC)no subject
Date: 2010-04-05 05:12 am (UTC)no subject
Date: 2010-04-05 07:32 am (UTC)no subject
Date: 2010-04-05 07:33 am (UTC)no subject
Date: 2010-04-05 07:34 am (UTC)(note the . at the end, freaking dots)
no subject
Date: 2010-04-05 07:49 am (UTC)Thank you so much for trying to help!
no subject
Date: 2010-04-09 10:14 am (UTC)And yes, potentially you can configure the VM to run on a private network, and you can just give the VM a static IP address on that private network. I'm not sure how to do that using VMWare, since I use VirtualBox for the purpose, but the principle is the same regardless. Pick a different private network address range to whatever you're presumably already using for your home private network.
no subject
Date: 2010-04-09 10:19 am (UTC)Once you've done that, then just set up Ubuntu on that virtual machine with everything you need - don't try and rely on installing and running development stuff on Snow Leopard. I <3 Mac OS X, but an open source friendly development environment, it is not.
no subject
Date: 2010-04-30 06:13 am (UTC)no subject
Date: 2010-05-03 02:18 am (UTC)Check what the ubuntu VM's ip address is, and add that at the front of your DNS servers.
Note that that may cause issues if your VM isn't running, so you can add in the Google Public DNS servers after the VM one: 8.8.8.8 and 8.8.4.4.
You'll be bypassing whatever your ISP is telling you to use as a DNS resolver, essentially, and using the VM's BIND instead (and then using the Google Public DNS if that's not available).
You may have to change that Advanced DNS setting for each type of network you're connected via (Ethernet, Wifi, etc).
no subject
Date: 2010-05-03 02:19 am (UTC)