Actually, you should qualify that a bit more. Ruby is rarely used outside of Ruby on Rails in North America. In Japan, it is widely used and Ruby on Rails is fair less common.
Ruby is a very versatile language in its own right. While the other poster is correct that it is used for anything that perl and python are used for it's also taking a large chunk from the Java and C# crowd in Japan. Everything from server side applications to command line tools and even GUI based desktop applications can be written in Ruby. Using FFI I have made some quite amazing applications with Ruby.
Rails is amazing and I personally love it. But it's not the only thing Ruby is good for.