In my first approach I was running the Sinatra app for the REST API of my blog (for ratings etc.) from command line. This has the drawback that the HTTP daemon integrated in Sinatra listens on a different port than the rest of the blog. This leads to same origin problems when ajaxing the REST API. To circumvent this I’ve used a small proxy script as a workaround. But now I’ve found Passenger (aka. mod_ruby) and migrated my blog to a rack unit. The static content is still served as static content via Apache. But the Sinatra app runs now via Apache, too. Passenger is the Rack implementation for Apache and Nginx.
Passenger On Board
7. April 2012 • edited 26. May 2020