we run centos and nginx one of latest versions in 2016. We use 1 media directory with some underlying subdirectories. FTTB for php is 200ms which is very fast – but now I discovered that the JS CSS and JPG statis content also has 200ms FTTB (download is fast at only 30ms) ….
question: what is a working nginx directive so we can optimze our nginx config for the statis content? (so files are served insanely fast)
Currently all files are on the same server as the mother php file. But I don't believe a CDN makes a lot of difference. Or would it?
help appreciated
location /media {
fttb = super_fast;
}
References I found:
– https://www.nginx.com/resources/admin-guide/serving-static-content/
Best Answer
This is our solution so far - but it looks like our server was already configured for speed. Improvements are welcome.