1. Do I have to setup anything at all to let Nginx processes them directly instead of proxy the request to apache?
  1. I thought I would have to added something to the domains config, I thought about a CUSTOM3 token in the nginx file. I tried this:

Code:

location ~* \.(ico|gif|jpeg|png|jpg|mp4)$ {
	try_files $uri $uri/ /$uri;
	add_header X-Test-Nginx-Bypass "OK";
	expires 15m;
}

Now I do get the header returned that says OK. But is it really OK or did I just manage to output an extra header? I tried to search for log entries but I'm not sure where I can check to make sure it works.

  1. Is my code correct, and will this also proxy the request correctly to apache if the file was not found?

ที่มา : https://forum.directadmin.com/threads/static-image-processing-configuration.54002/