Hello, I have read many answers here, but my goal it is to install the pagespeed on ubuntu without make disasters. I have see that need to “reinstall” the nginx, but is it possible using the packages system? And which are the steps to do withotu to risk to lose the existing web portal?
Thank you very much and sorry for my poor english
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
This is out of date; there’s now an automated installer for ngx_pagespeed: build_ngx_pagespeed_from_source
It’s also suggesting people build ngx_pagespeed version 1.9, which has unpatched security vulnerabilities in HTTPS fetching.
Unfortunately, the pagespeed module is not available from the official page repositories. In order to use it with Nginx, you’ll need to build Nginx from source. These directions are based on the ones from the ngx_pagespeed Google Code page, but they have been somewhat changed to be a better drop in replacement for the packaged version.
First install the build dependencies:
Then download ngx_pagespeed:
Now we’ll build Nginx with the pagespeed module (note the
configure
arguments are different from the version provided by upstream):It should now be installed and available. Before removing the old Nginx package, we need to do one more thing. Let’s copy the init script that comes with the package and modify it to work with the new version:
Now remove the package:
Finally, enable pagespeed by adding the following to
/etc/nginx/nginx.conf
And start it with:
Unfortunately, the pagespeed module is not available from the official page repositories. In order to use it with Nginx, you’ll need to build Nginx from source. These directions are based on the ones from the ngx_pagespeed Google Code page, but they have been somewhat changed to be a better drop in replacement for the packaged version.
First install the build dependencies:
Then download ngx_pagespeed:
Now we’ll build Nginx with the pagespeed module (note the
configure
arguments are different from the version provided by upstream):It should now be installed and available. Before removing the old Nginx package, we need to do one more thing. Let’s copy the init script that comes with the package and modify it to work with the new version:
Now remove the package:
Finally, enable pagespeed by adding the following to
/etc/nginx/nginx.conf
And start it with:
Unfortunately, the pagespeed module is not available from the official page repositories. In order to use it with Nginx, you’ll need to build Nginx from source. These directions are based on the ones from the ngx_pagespeed Google Code page, but they have been somewhat changed to be a better drop in replacement for the packaged version.
First install the build dependencies:
Then download ngx_pagespeed:
Now we’ll build Nginx with the pagespeed module (note the
configure
arguments are different from the version provided by upstream):It should now be installed and available. Before removing the old Nginx package, we need to do one more thing. Let’s copy the init script that comes with the package and modify it to work with the new version:
Now remove the package:
Finally, enable pagespeed by adding the following to
/etc/nginx/nginx.conf
And start it with:
This comment has been deleted