How to config NGINX to serve uploaded carrierwave files from RAILS_ROOT/public/uploads ? e.g: http://deckbuilder.justnetwork.eu//uploads/card/image/173/54.png
The files are getting served when config.serve_static_assets = true but this is slow. I want NGINX to serve them. The CS, JS and images are getting served.
Here's a excerpt from my NGINX config:
root /var/www/hsdeckbuilder/public;
try_files $uri/index.html $uri.html $uri @app;
location @app {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_pass http://localhost:8101;
proxy_send_timeout 3600;
proxy_read_timeout 3600;
}