We are looking to install Squid to hopefully speed up some of the pages on our website. We use Ubuntu, so besides installing and configuring the package for Squid, what configuration needs to be done in Matrix in order to start using Squid? Is there any documentation for this?
Squid can be setup in a few ways to add the caching proxy that you are looking for.
The exact setup will be based on your own system needs. As a rev proxy Squid is fairly independent of Matrix and only has 2 main interactions.
Lastly if your debugging check you headers in the first instance.
Reviewing the headers returned from a curl on 127.0.0.1:80 can provide information that caching proxies can sometimes choose to override or exclude. Keeping in mind the default config should allow headers to passthrough seamlessly so other upstream proxies follow the same page rules.
And some other useful config for your squid.conf file.
# use this if you have a single squid in front of a single Matrix to avoid burying your backend if it's already struggling
retry_on_error off
# This block avoids caching backend related content
acl QUERY urlpath_regex /_edit /_admin /_login /_nocache /_recache /_performance /__lib /__fudge
acl POST method POST
cache deny QUERY
cache deny POST
# if the site experiences high traffic this will be required
# see also "ulimit -n <number of file descriptors>"
max_filedesc 8192
# To ensure we honour cache headers on 404s from Matrix we need to ensure there is
# some positive value in negative_ttl, as long as there is, Squid honours the
# timings set by Matrix.
negative_ttl 1 second