A rewrite of the Spring Fortune Teller demo in Ruby, made of two components, the UI and the Fortune Service.
Both applications are simple Sinatra applications using the Rack.
- Start the Fortune Service
cd fortune-teller-server
rackup -p 9293
- In a sercond terminal, start the UI
cd fortune-teller-ui
rackup
- Access the UI at http://localhost:9292
By default, the UI will look for the Fortune Service at http://localhost:9293, however this can be changed when deployed to Cloud Foundry using a User-Provided Service and binding it to the deployed version of the UI.
cf create-user-provided-service fortune-server -p '{"url":"http://fortune-server.cfapps.io"}'
cf bind-service fortune-ui fortune-server