I found several and somewhat complex solutions for this particular problem but actually it’s a no-brainer once you know. Simply type:
hukl$ script/server -h => Booting Mongrel (use 'script/server webrick' to force WEBrick) Usage: server [options] -p, --port=port Runs Rails on the specified port. Default: 3000 -b, --binding=ip Binds Rails to the specified ip. Default: 0.0.0.0 -d, --daemon Make server run as a Daemon. -e, --environment=name Specifies the environment to run this server under (test/development/production). Default: development -h, --help Show this help message.
The magic trick is to use sudo to start WEBrick, else the bind might not work and the webserver is unreachable for virtual machines or other hosts.
sudo script/server -b 10.0.2.1 -p 80
Yippeeh! Now I can test my Ruby on Rails projects, which are running on OS X, from my WinXP Paralles virtual machine using IE6 and IE7.
Main entry continued