Search Engine: Elastic

Article ID: 132340, created on Mar 7, 2018, last review on Mar 7, 2018

  • Applies to:
  • Operations Automation 7.3

Using the mod_deflate Apache module, you can compress the content of websites before it is delivered to clients. To learn more about the module, refer to the webpage.

Note: This module is supported since CloudLinux 6.

To enable mod_deflate for all websites on a WebHosting Linux node, complete the following steps:

  1. Open for editing the Apache configuration file.

  2. Locate the line "LOADMODULE deflate_module modules/".

  3. To compress the most common text-based types of files, paste the following text below this line:

    <Directory "/var/www/vhosts">
        AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css text/javascript application/javascript
  4. Restart the Apache service:

    service httpd restart

Note: If you are using a WebHosting Linux cluster, carry out these steps for all nodes in the cluster.

To switch off the enforced compression for all websites:

  1. Remove the line that start with "AddOutputFilterByType DEFLATE" from the Apache configuration file.

  2. Restart the Apache service:

    service httpd restart

5356b422f65bdad1c3e9edca5d74a1ae caea8340e2d186a540518d08602aa065 e12cea1d47a3125d335d68e6d4e15e07 dd79f16c76b9dca75205ab5e9f5465ea 1941880841f714e458ae4dc3d9f3062d

Email subscription for changes to this article
Save as PDF