Rails 3 - Is there any fallback for when serving assets from an asset server fails?

Viewed 906

In my production.rb I've set this:

# Enable serving of images, stylesheets, and JavaScripts from an asset server
  config.action_controller.asset_host = "http://myassets.com"

And the images, js and stylesheets are loading fine from my CDN (assets server)

but what if someday this asset servers fails? and it returns a 404?

Because in my assets server (CDN) I have configure a pull zone, the content is still available from /assets/...

Is there any fallback or how can I make a fallback so when my assets server fails or return error my application loads assets from /assets/ inside the application?

2 Answers
Related