I’m setting up my devel environment for an Ember.js app using rake-pipeline as described here.
During development, my html and javascript are served by webrick (rake-filter magic that I don’t quite understand) on http://0.0.0.0:9292 and I have a REST service developed in php served by Apache on http://somename.local
My ajax calls from the client app are getting lost because of the browser’s anti-cross-domain-ajax thing. How do I work around this issue?
You can’t configure the proxy directly in your Assetfile. You’ll have to create a
config.rufile and use therackupcommand to launch the server.Here’s an example Assetfile:
And config.ru:
You’ll have to install the rack and rack-streaming-proxy gems.