Google Page Speed Module & ngx_pagespeed with EasyEngine


Do I need to do the below steps for Google PageSpeed module from Google’s instructions or is it duplication of this I ended up doing both, and it’s performing faster, but I’m wondering now if I installed stuff I did not need or duplicated efforts, and if this would hurt me later.

I followed Google’s instructions for page speed here:

Build ngx_pagespeed From Source

To install our dependencies, run:

Ubuntu or Debian

sudo apt-get install build-essential zlib1g-dev libpcre3 libpcre3-dev unzip

Then download ngx_pagespeed:

unzip release-${NPS_VERSION}
cd ngx_pagespeed-release-${NPS_VERSION}-beta/
tar -xzvf ${NPS_VERSION}.tar.gz  # extracts to psol/

Module Configuration

In Nginx you need to add several lines to your nginx.conf. In every server block where PageSpeed is enabled add:

pagespeed on;

# Needs to exist and be writable by nginx.  Use tmpfs for best performance.
pagespeed FileCachePath /var/ngx_pagespeed_cache;

# Ensure requests for pagespeed optimized resources go to the pagespeed handler
# and no extraneous headers get set.
location ~ "\.pagespeed\.([a-z]\.)?[a-z]{2}\.[^.]{10}\.[^.]+" {
  add_header "" "";
location ~ "^/pagespeed_static/" { }
location ~ "^/ngx_pagespeed_beacon$" { }

Hi @JDdiego

EasyEngine uses a custom build of Nginx which has pagespeed module built-in, which makes above steps redundant.

I am closing this support topic for now. Feel free to create a new support topic if you have any queries further. :slight_smile: