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 RHEL 6 support #368

Merged
merged 1 commit into from
Jun 29, 2023
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
2 changes: 0 additions & 2 deletions data/os/RedHat/CentOS/5.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions data/os/RedHat/CentOS/6.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions data/os/RedHat/OracleLinux/5.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions data/os/RedHat/OracleLinux/6.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions data/os/RedHat/RedHat/5.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions data/os/RedHat/RedHat/6.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions data/os/RedHat/Scientific/5.yaml

This file was deleted.

2 changes: 0 additions & 2 deletions data/os/RedHat/Scientific/6.yaml

This file was deleted.

6 changes: 0 additions & 6 deletions lib/puppet/provider/selinux_fcontext/semanage.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,7 @@

mk_resource_methods

osfamily = Facter.value('osfamily')
osversion = Facter.value('operatingsystemmajrelease')
operatingsystem = Facter.value('operatingsystem')
@old_semanage = false
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is now redundant. So you can also simplify it further: #372

if (osfamily == 'RedHat') && (Puppet::Util::Package.versioncmp(osversion, '6') <= 0) && (operatingsystem != 'Amazon')
@old_semanage = true
end

@file_types = {
'all files' => 'a',
Expand Down
2 changes: 0 additions & 2 deletions metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,13 @@
{
"operatingsystem": "RedHat",
"operatingsystemrelease": [
"6",
"7",
"8"
]
},
{
"operatingsystem": "CentOS",
"operatingsystemrelease": [
"6",
"7",
"8"
]
Expand Down
12 changes: 11 additions & 1 deletion spec/classes/selinux_package_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

describe 'selinux' do
context 'package' do
%w[6 7].each do |majrelease|
%w[7].each do |majrelease|
context "On RedHat #{majrelease} based OSes" do
let(:facts) do
{
Expand All @@ -14,6 +14,7 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.to contain_package('policycoreutils-python').with(ensure: 'installed') }
it { is_expected.not_to contain_package('auditd') }
end
Expand All @@ -30,6 +31,7 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.to contain_package('policycoreutils-python-utils').with(ensure: 'installed') }
end

Expand All @@ -45,6 +47,7 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.to contain_package('policycoreutils-python-utils').with(ensure: 'installed') }
end
end
Expand All @@ -60,6 +63,7 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.to contain_package('policycoreutils').with(ensure: 'installed') }
end

Expand All @@ -74,6 +78,8 @@
}
end

it { is_expected.to compile.with_all_deps }

%w[policycoreutils-python-utils selinux-basics selinux-policy-default auditd].each do |package|
it { is_expected.to contain_package(package).with(ensure: 'installed') }
end
Expand All @@ -94,6 +100,7 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.not_to contain_package('policycoreutils-python').with(ensure: 'installed') }
end

Expand All @@ -112,6 +119,7 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.to contain_package('some_package').with(ensure: 'installed') }
end

Expand All @@ -130,6 +138,7 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.to contain_package('setroubleshoot').with(ensure: 'installed') }
it { is_expected.to contain_package('setroubleshoot-plugins').with(ensure: 'installed') }
end
Expand All @@ -149,6 +158,7 @@
}
end

it { is_expected.to compile.with_all_deps }
it { is_expected.to contain_package('policycoreutils-sandbox').with(ensure: 'installed') }
it { is_expected.to contain_package('selinux-policy-sandbox').with(ensure: 'installed') }
end
Expand Down