apache2
apache2 copied to clipboard
Amazon 2018 install broken with PR#688
:ghost: Brief Description
In PR#688, the apache_pkg helper libraries/helpers.rb is modified to remove
when 'amazon'
if node['platform_version'] == '2'
'httpd'
else
'httpd24'
end
for this static instead
when 'amazon'
'httpd'
This causes the httpd package (apache2.2) to be downloaded from the Amazon repo instead of httpd24 (apache2.4). 2.2 should not be downloaded by default
:pancakes: Cookbook version
8.2.0
:woman_cook: Chef-Infra Version
16.2.50
:tophat: Platform details
amazon, 2018.03
Steps To Reproduce
Steps to reproduce the behavior:
- On Amazon Linux instance, run a default_install. I was never able to get Chef to get to a site config because my httpd.conf.erb is built for 2.4, not 2.2.
- After error, check httpd version
httpd -vyum info httpd. You should be able to runyum info httpd24and see it listed as an installed package, but it only shows available.
:police_car: Expected behavior
The httpd24 package is expected to install (has been since cookbook v6 at least).
:heavy_plus_sign: Additional context
PR#688 appears to have broken the libraries/helpers.rb. Code is also modified in spec/libraries/package_helpers_spec.rb. I have not tested the affects of this change.
context 'with amazon family' do
context 'on amazon-1' do
platform 'amazon', '2018'
it { is_expected.to write_log('httpd24') }
end
context 'on amazon-2' do
platform 'amazon', '2'
it { is_expected.to write_log('httpd24') }
end
end