diff --git a/manifests/api.pp b/manifests/api.pp index 38e3b21..527b133 100644 --- a/manifests/api.pp +++ b/manifests/api.pp @@ -66,4 +66,14 @@ class openstack_health::api( Exec['package-application'], ], } + if ! defined(Httpd::Mod['cache']) { + httpd::mod { 'cache': + ensure => present, + } + } + if ! defined(Httpd::Mod['cache_disk']) { + httpd::mod { 'cache_disk': + ensure => present, + } + } } diff --git a/templates/openstack-health-api.vhost.erb b/templates/openstack-health-api.vhost.erb index 1b82e42..3f7b260 100644 --- a/templates/openstack-health-api.vhost.erb +++ b/templates/openstack-health-api.vhost.erb @@ -23,5 +23,15 @@ WSGIPythonHome <%= scope.lookupvar("openstack_health::api::virtualenv_dir") %> Require all granted + + + CacheRoot "/var/cache/apache2/mod_disk_cache" + CacheEnable disk "/" + CacheDirLevels 5 + CacheDirLength 3 + CacheLock on + + + DocumentRoot <%= scope.lookupvar("openstack_health::api::api_dir") %>