From 10a49a5d89da09e70f422402ee646484f2a9115c Mon Sep 17 00:00:00 2001 From: Evgeni Golov Date: Wed, 27 Nov 2024 14:31:18 +0100 Subject: [PATCH] include mod_expire on el9 for web and downloads --- puppet/modules/web/manifests/vhost/downloads.pp | 7 +++++++ puppet/modules/web/manifests/vhost/web.pp | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/puppet/modules/web/manifests/vhost/downloads.pp b/puppet/modules/web/manifests/vhost/downloads.pp index b4c81d500..b14d66475 100644 --- a/puppet/modules/web/manifests/vhost/downloads.pp +++ b/puppet/modules/web/manifests/vhost/downloads.pp @@ -33,6 +33,13 @@ directories => $downloads_directory_config, } + # vhosts don't autorequire the expires module + # https://github.com/puppetlabs/puppetlabs-apache/pull/2559 + # limit to not EL7 as there we use apache::default_mods + if $facts['os']['family'] != 'RedHat' or $facts['os']['release']['major'] != '7' { + include apache::mod::expires + } + file { "${downloads_directory}/HEADER.html": ensure => file, owner => 'root', diff --git a/puppet/modules/web/manifests/vhost/web.pp b/puppet/modules/web/manifests/vhost/web.pp index e5c02f896..d15e197d3 100644 --- a/puppet/modules/web/manifests/vhost/web.pp +++ b/puppet/modules/web/manifests/vhost/web.pp @@ -79,6 +79,13 @@ }, } + # vhosts don't autorequire the expires module + # https://github.com/puppetlabs/puppetlabs-apache/pull/2559 + # limit to not EL7 as there we use apache::default_mods + if $facts['os']['family'] != 'RedHat' or $facts['os']['release']['major'] != '7' { + include apache::mod::expires + } + secure_ssh::rsync::receiver_setup { 'web': user => 'website', foreman_search => 'host ~ node*.jenkins.osuosl.theforeman.org and (name = external_ip4 or name = external_ip6)',