font_assets icon indicating copy to clipboard operation
font_assets copied to clipboard

Production enviroment issue

Open tanelsuurhans opened this issue 13 years ago • 3 comments

I'm kind of at loss how this is supposed to work in production environments. Static assets are supposed to be served directly by the webserver (apache/nginx), instead of passing through Rails. This means that the middleware will not kick in and the headers would not be set. Am I missing something here?

tanelsuurhans avatar Nov 30 '12 15:11 tanelsuurhans

Our assets are served by the Rails app because we are on Heroku's cedar stack. Our CDN makes the requests for the asset, and we want that asset to be served with correct Access-Control headers from the CDN. Thus, this middleware.

ericallam avatar Nov 30 '12 16:11 ericallam

Gotcha, in this case it makes sense. So when i'm serving assets via my web server, i just need to handle adding those headers in there. Thanks a bunch.

tanelsuurhans avatar Nov 30 '12 16:11 tanelsuurhans

Looks like this issue can be closed. =)

reconbot avatar Oct 23 '13 14:10 reconbot