Skip to content

Instantly share code, notes, and snippets.

@changeme
Last active November 3, 2017 01:11
Show Gist options
  • Save changeme/083f5c55cd75ed6e2bd15f6bb4de5108 to your computer and use it in GitHub Desktop.
Save changeme/083f5c55cd75ed6e2bd15f6bb4de5108 to your computer and use it in GitHub Desktop.
Instalacion de mod_pagespeed en cPanel
/usr/local/cpanel/3rdparty/bin/git clone https://github.com/pagespeed/cpanel.git /tmp/pagespeed/
cd /tmp/pagespeed/Easy
tar -zcvf Speed.pm.tar.gz pagespeed
mkdir -p /var/cpanel/easy/apache/custom_opt_mods/Cpanel/Easy
mv Speed.pm Speed.pm.tar.gz -t /var/cpanel/easy/apache/custom_opt_mods/Cpanel/Easy/
cd && rm -rf /tmp/pagespeed
## Continuar instalando desde EasyApache
echo '%_httpd_mmn 20120211x8664
%_httpd_apxs /usr/bin/apxs
%_httpd_dir /etc/apache2
%_httpd_bindir %{_httpd_dir}/bin
%_httpd_modconfdir %{_httpd_dir}/conf.modules.d
%_httpd_confdir %{_httpd_dir}/conf.d
%_httpd_contentdir /usr/share/apache2
%_httpd_moddir /usr/lib64/apache2/modules' >> /etc/rpm/macros.apache2
yum install rpm-build cpio ea-apache24-mod_version
wget https://github.com/pagespeed/cpanel/raw/master/EA4/ea-apache24-mod_pagespeed-latest-stable.src.rpm
rpmbuild --rebuild ea-apache24-mod_pagespeed-latest-stable.src.rpm
rpm -ivh /root/rpmbuild/RPMS/x86_64/ea-apache24-mod_pagespeed*.rpm
service httpd restart
httpd -t -D DUMP_MODULES|egrep -i pagespeed --color
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment