Please refer to the Optimizely X: Full Stack Ruby Documentation.
This demo app will show using the Ruby SDK to roll out a new sorting feature.
gem install optimizely-sdk
sudo gem install -n /usr/local/bin/ httparty
sudo gem install -n /usr/local/bin/ sinatra
sudo gem install -n /usr/local/bin/ csv_hasher
cd ruby_full_stack_demo/
ruby bin/app.rb
Then go to http://localhost:8080
To update the Otpimizely variation code, view the bin/app.rb file