News for hackers. Stuff that matters.
Re:Change http://localhost:3000 to myapp.dev with marathon-dns by brandon_wirtz on Sunday May 05, 2013 @03:54PM (#5659522)
I do this with Squid, or Fiddler depending on platform.

I have done a similar trick for the entire lan by doing port forwarding on DD-WRT and similar.

I pretty routinely highjack ports as domains for doing local testing. If I want to make sure that I'm hitting my own cached version of an API that I need to consume from a third party I just serve it from local. That way I can dev offline, or guarantee that I will always get the same response, or a much faster response. I could Mock it, or do a number of other things, but it is often nice to be able to see what is going over the wire, and using a proxy to handle the redirect and port change is one of the best ways to do so.

Re:Change http://localhost:3000 to myapp.dev with marathon-dns by jstanley on Sunday May 05, 2013 @03:27PM (#5659438)
Or with /etc/hosts

EDIT: Oops. Didn't notice the port number part.

Re:Change http://localhost:3000 to myapp.dev with marathon-dns by t0 on Sunday May 05, 2013 @03:52PM (#5659517)
Is this just a proxy? It seems like this script accepts packets and forwards them on to localhost.
Re:Change http://localhost:3000 to myapp.dev with marathon-dns by davewasmer on Sunday May 05, 2013 @03:57PM (#5659531)
It's a combination of a proxy, a DNS server, a ipfw rule, and a resolver file. All that is needed to allow you to capture port 80 traffic without running your application server with sudo every time.
Re:Change http://localhost:3000 to myapp.dev with marathon-dns by ansman on Monday May 06, 2013 @02:04AM (#5661105)
The readme is very unclear, I've installed it but it doesn't appear that it's doing anything.
Re:Change http://localhost:3000 to myapp.dev with marathon-dns by fn on Sunday May 05, 2013 @04:22PM (#5659602)
I do this with Vagrant and the vagrant-hostmaster gem.
Re:Change http://localhost:3000 to myapp.dev with marathon-dns by sebcioz on Sunday May 05, 2013 @04:44PM (#5659662)
What about subdomains? Does it support them?