Ruby is installed on all DreamHost servers by default. You can confirm the version installed by logging into your server via SSH and running the following command:
[server]$ ruby -v
Ruby on Shared Hosting
Due to the amount of memory Ruby on Rails may use, running an app on Shared Hosting is not recommended as it will most likely hit the shared server's memory limits.
Installing a current version of Ruby
VPS and Dedicated servers allow you to install any version you like using Ruby Version Manager.