diff --git a/modules/openstack_project/manifests/mirror.pp b/modules/openstack_project/manifests/mirror.pp index 4b8e3b56cd..68fa5bd4e8 100644 --- a/modules/openstack_project/manifests/mirror.pp +++ b/modules/openstack_project/manifests/mirror.pp @@ -267,6 +267,23 @@ class openstack_project::mirror ( ] } + # Cache cleanup + package { 'apache2-utils': + ensure => present, + } + + cron { 'apache-cache-cleanup': + # Clean apache cache once an hour, keep size down to 2GB. + minute => '0', + hour => '*', + command => 'htcacheclean -n -p /opt/apache_cache -t -l 2048M > /dev/null', + environment => 'PATH=/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin', + require => [ + File['/opt/apache_cache'], + Package['apache2-utils'], + ], + } + class { '::httpd::logrotate': options => [ 'daily',