Getting Local Hostname

Joe Smith wrote:

How can I get the local hostname in Rails? Or Ruby for that matter.

Cheat:

me = `hostname`

Note the backticks ``

If that don't work, cheat harder.

or better yet

in rails:

ENV["HOSTNAME"]

Chris