Lofesa commented on issue #1720:
URL:
https://github.com/apache/incubator-pagespeed-ngx/issues/1720#issuecomment-731769994
Hi
1.- these 3 files have a mixed directives content. Some are needed for the
server block you enable pagespeed or can be set at http block, but other are
needed only in the server block you use to view the console and stats pages.
And for the nignx logic all tree files must be set in a server block (you have
`include pagespeed.conf;` in the http block). Niginx uses this:
```
http{
server {
location{
}
}
}
```
Maybe a reorder of these files is needed, making all directives for
statistics, console and other in 1 file for each, and not spreaded in these 3.
2.- All these fastcgi are used ONLY where you have php locations, so you can
put it together and have all fascgi directives only in one point and not spread
it.
3.- Personally I use only `pagespeed on;` ony in the server blocks I need
it, and a explicit `pagespeed unplugged;` in those I don´t need.
4.- I think you don´t need `pagespeed MapOriginDomain "http://uhl.site"
"https://uhl.site";` at all.
5.- this if is not needed, like `if ($server_port !~ 443)` (in uhl.site.conf
lines 77 - 80). These directives make sense when you have a server block with
ports 80 and 443 enabled, but you have these ports in diferent server blocks so
waste resources making a test not need. It works? sure, but you have not
enabled https in the 80 port so a https never reach this server, and you have
only enabled the 443 in the server block thus a request to others port never
reach this.
9.- You can use Redis. In the docs say "experimental" but don´t is. Is safe
and estable, and for me better option that memcached.
10.- You have brotli and gzip enabled in the http block. and these are
applied to .pagespeed. resources too.
11.- Pagespeed may have bad consecuences in the admin area for wordpress.
Better disabled for it. Same for the fastcgi cache, you don´t need the wp-login
cached.
12.- You are not serving binary content by default but text/html, better
change it.
**13.- I see you have an other include directive i´m not aware before:
`include proxy.conf;`. I can´t see any config directive that say you are using
a proxy, so maybe the directives in this files introduces some distortion on
how the site works.**
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]