Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop EoL EL7 support #106

Merged
merged 1 commit into from
Sep 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 0 additions & 14 deletions metadata.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{

Check warning on line 1 in metadata.json

View workflow job for this annotation

GitHub Actions / Puppet / Static validations

Skipping EOL operating system Debian 10

Check warning on line 1 in metadata.json

View workflow job for this annotation

GitHub Actions / Puppet / Static validations

Skipping EOL operating system Debian 11

Check warning on line 1 in metadata.json

View workflow job for this annotation

GitHub Actions / Puppet / Static validations

Skipping EOL operating system Ubuntu 18.04

Check warning on line 1 in metadata.json

View workflow job for this annotation

GitHub Actions / Puppet / Static validations

Skipping EOL operating system CentOS 8
"name": "puppet-ipset",
"version": "4.3.1-rc0",
"author": "Vox Pupuli",
Expand Down Expand Up @@ -37,15 +37,13 @@
{
"operatingsystem": "RedHat",
"operatingsystemrelease": [
"7",
"8",
"9"
]
},
{
"operatingsystem": "CentOS",
"operatingsystemrelease": [
"7",
"8",
"9"
]
Expand All @@ -71,18 +69,6 @@
"9"
]
},
{
"operatingsystem": "Scientific",
"operatingsystemrelease": [
"7"
]
},
{
"operatingsystem": "VirtuozzoLinux",
"operatingsystemrelease": [
"7"
]
},
{
"operatingsystem": "Archlinux"
}
Expand Down
26 changes: 6 additions & 20 deletions spec/classes/init_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,7 @@
on_supported_os.each do |os, facts|
context "on #{os}" do
let :facts do
if facts[:os]['release']['major'].to_i == 6
facts.merge(systemd: false, service_provider: 'redhat')
else
facts.merge(systemd: true, service_provider: 'systemd')
end
facts
end

context 'with all defaults' do
Expand All @@ -31,22 +27,12 @@
it { is_expected.not_to contain_file('/etc/sysconfig/ipset.d') }
end

if facts[:os]['release']['major'].to_i == 6
it { is_expected.not_to contain_systemd__unit_file('ipset.service') }
it { is_expected.to contain_service('ipset') }
it { is_expected.to contain_file('/etc/init.d/ipset') }
else
it { is_expected.to contain_systemd__unit_file('ipset.service') }
# ipset service is configured via camptocamp/systemd
it { is_expected.not_to contain_service('ipset') }
it { is_expected.not_to contain_file('/etc/init/ipset.conf') }
end
it { is_expected.to contain_systemd__unit_file('ipset.service') }
# ipset service is configured via camptocamp/systemd
it { is_expected.not_to contain_service('ipset') }
it { is_expected.not_to contain_file('/etc/init/ipset.conf') }

if facts[:os]['family'] == 'RedHat' && facts[:os]['release']['major'].to_i >= 7
it { is_expected.to contain_package('ipset-service') }
else
it { is_expected.not_to contain_package('ipset-service') }
end
it { is_expected.to contain_package('ipset-service') } if facts[:os]['family'] == 'RedHat'
end

context 'with sets attributes' do
Expand Down