-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature Request: Nginx Support #322
Comments
What options would there be for GZIP compression on Nginx? This is something that is enabled at the server config. level in Nginx. Is there a way for ZenCache to say otherwise? Or, is the idea that we would provide instructions about how to enable GZIP when running Nginx? i.e., provide details about Nginx server configuration? |
Gzip is enabled server side for apache too. If one is going the distance to offer to enable this for apache instances ( clearly quickcache is doing htaccess modification ), then why is it is confounding to at least investigate the viability of altering the nginx config, or at the very least, providing a snippet for the user to include in their nginx config. |
@fhumayun writes...
Not confounding, I just want to clarify what you are asking for. Thank you for doing so. |
Apologies for the verbiage then. I was under the impression that your series of inquiries was flow-charting the request as not worthy of any pursuit out of hand. |
Referencing this page that includes several Nginx-specific rules for various caching plugins: https://codex.wordpress.org/Nginx We should investigate what specifically needs to be done to optimize Nginx for ZenCache and come up with a list of applicable rules for ZenCache (if any). |
Suggested Nginx Configuration for ZenCacheserver {
etag on;
expires 7d;
if_modified_since before;
gzip on;
gzip_vary on;
gzip_comp_level 6;
gzip_types text/plain text/xml image/svg+xml # text/html in core already.
application/rss+xml application/atom+xml application/xhtml+xml
text/css application/json application/x-javascript
application/font-otf application/font-ttf;
} See also, my full example here: https://github.com/jaswsinc/vagrant-ubuntu-lemp/blob/master/assets/nginx/.conf |
Suggested Apache Configuration for ZenCacheI'll go ahead and post this here, just to keep both together for now. FileETag MTime Size
<IfModule expires_module>
ExpiresActive on
ExpiresDefault "access plus 1 week"
</IfModule>
<IfModule deflate_module>
<IfModule filter_module>
AddOutputFilterByType DEFLATE text/plain text/html
AddOutputFilterByType DEFLATE text/xml application/xml application/xhtml+xml application/xml-dtd
AddOutputFilterByType DEFLATE application/rdf+xml application/rss+xml application/atom+xml image/svg+xml
AddOutputFilterByType DEFLATE text/css text/javascript application/javascript application/x-javascript
AddOutputFilterByType DEFLATE font/otf font/opentype application/font-otf application/x-font-otf
AddOutputFilterByType DEFLATE font/ttf font/truetype application/font-ttf application/x-font-ttf
<IfModule headers_module>
<FilesMatch "\.(js|css|xml|svg|xhtml|html|txt|ttf|otf|gz)$">
Header append Vary: Accept-Encoding
</FilesMatch>
</IfModule>
</IfModule>
</IfModule> |
Greetings,
I have the Quick Cache Pro plugin, and was hoping to request future support for Nginx ( especially for options like gzip compression ).
Cheers,
Faisal
http://seekeraftertruth.com
The text was updated successfully, but these errors were encountered: