NGINX conf file missing? Reverse proxy?

Avatar
  • updated
  • Answered

Hi -

I want to protect certain media library files from being accessible via direct access in WordPress to users who are not logged in.   (Permalinks are easy to protect, but the files themselves are still accessible by direct access, and I want only logged in users to be able to access certain files).  I am attempting to use the "Protect WordPress Uploads" plugin, which essentially moves the files you want to protect into another (private) folder rather than the typical location for WordPress uploads - and then protects that location. The developer notes that sites using NGINX servers need to include a rewrite in the NGINX configuration file (which is usually found in the etc folder in File Manager) to restrict that folder for direct access (then specifying the location with a "deny all" directive).  I have the code ready to copy and paste for this rewrite.


In looking at the headers for my website (clearheartsquaker.org), it appears that NGINX servers are being used for my site.  However, when I go to File Manager, there is no NGINX config file in the etc folder, or anywhere else on my site that I've seen.  I've been reading about NGINX reverse proxy configurations - I assume that might be what I have going on?


How do I access the NGINX configuration file to make the necessary changes?  Please be detailed... I haven't had to try this before, and am only just learning that NGINX and Apache are different server things, let alone how they work.  Thanks in advance! :)
 

Pinned replies
Avatar
Alyssa K
  • Answer
  • Answered

Hi, 

Thank you for your question regarding NGINX configurations. If you are operating on a shared server, it is unlikely that the NGINX configuration files will be accessible via the file manager. Alternatively, you may need to enable hidden files in the File Manager. Please let us know if you have any further questions, we are happy to help!

Best Regards,

Alyssa K.

Avatar
Alyssa K
  • Answer
  • Answered

Hi, 

Thank you for your question regarding NGINX configurations. If you are operating on a shared server, it is unlikely that the NGINX configuration files will be accessible via the file manager. Alternatively, you may need to enable hidden files in the File Manager. Please let us know if you have any further questions, we are happy to help!

Best Regards,

Alyssa K.