Skip to content

Commit

Permalink
Support perfSONAR 5, Drop EL7 and Debian 10 (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
treydock authored Apr 10, 2024
1 parent 35137a5 commit 1cc9da6
Show file tree
Hide file tree
Showing 12 changed files with 33 additions and 121 deletions.
15 changes: 8 additions & 7 deletions .fixtures.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,19 @@

---
fixtures:
repositories:
forge_modules:
stdlib:
repo: https://github.com/puppetlabs/puppetlabs-stdlib.git
repo: puppetlabs/stdlib
apt:
repo: https://github.com/puppetlabs/puppetlabs-apt.git
repo: puppetlabs/apt
yumrepo_core:
repo: https://github.com/puppetlabs/puppetlabs-yumrepo_core.git
repo: puppetlabs/yumrepo_core
firewall:
repo: https://github.com/puppetlabs/puppetlabs-firewall.git
repo: puppetlabs/firewall
ref: '6.0.0'
epel:
repo: https://github.com/voxpupuli/puppet-epel.git
repo: puppet/epel
httpauth:
repo: https://github.com/jamtur01/jamtur01-httpauth.git
repo: jamtur01/httpauth
symlinks:
perfsonar: "#{source_dir}"
3 changes: 0 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,8 @@ jobs:
fail-fast: false
matrix:
set:
- "el7"
- "el8"
- "el9"
- "debian-10"
- "ubuntu-2004"
puppet:
- "puppet7"
- "puppet8"
Expand Down
10 changes: 7 additions & 3 deletions .sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
.github/workflows/ci.yaml:
acceptance_matrix:
set:
- el7
- ---el7
- el8
- el9
- debian-10
- ubuntu-2004
# Repos are currently broken
- ---ubuntu-2004
puppet:
- puppet7
- puppet8
Expand All @@ -19,8 +19,12 @@ Gemfile:
':development':
- gem: rspec-json_expectations
- gem: webrick
spec/acceptance/nodesets/el7.yml:
delete: true
spec/acceptance/nodesets/debian-11.yml:
delete: true
spec/acceptance/nodesets/debian-12.yml:
delete: true
spec/acceptance/nodesets/ubuntu-2204.yml:
delete: true
spec/spec_helper.rb:
Expand Down
6 changes: 3 additions & 3 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ ruby_version_segments = Gem::Version.new(RUBY_VERSION.dup).segments
minor_version = ruby_version_segments[0..1].join('.')

group :development do
gem "voxpupuli-test", '5.4.1', require: false
gem "voxpupuli-test", '7.0.0', require: false
gem "rspec-json_expectations", require: false
gem "webrick", require: false
gem "faraday", '~> 1.0', require: false
Expand All @@ -31,8 +31,8 @@ group :system_tests do
gem "beaker-pe", require: false
gem "beaker-hostgenerator"
gem "beaker-rspec"
gem "beaker-docker"
gem "beaker-puppet"
gem "beaker-docker", git: 'https://github.com/treydock/beaker-docker.git', branch: 'amazon-2023'
gem "beaker-puppet", git: 'https://github.com/puppetlabs/beaker-puppet.git', ref: '6063d22b6c4449df795731f5853c3c75241240c4'
gem "beaker-puppet_install_helper", require: false
gem "beaker-module_install_helper", require: false
end
Expand Down
2 changes: 1 addition & 1 deletion manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
class perfsonar (
Boolean $manage_repo = true,
Boolean $manage_epel = true,
Variant[Stdlib::HTTPUrl,Stdlib::HTTPSUrl] $release_url = "http://software.internet2.edu/rpms/el${facts['os']['release']['major']}/x86_64/latest/packages/perfsonar-repo-0.11-1.noarch.rpm",
Variant[Stdlib::HTTPUrl,Stdlib::HTTPSUrl] $release_url = "https://software.internet2.edu/rpms/el${facts['os']['release']['major']}/x86_64/latest/packages/perfsonar-repo-0.11-1.noarch.rpm",
Enum['perfsonar-tools','perfsonar-testpoint','perfsonar-core','perfsonar-centralmanagement','perfsonar-toolkit']
$bundle = 'perfsonar-toolkit',
Array $optional_packages = [],
Expand Down
22 changes: 10 additions & 12 deletions manifests/repo.pp
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,15 @@
if $perfsonar::manage_epel {
contain 'epel'
}
if versioncmp($facts['os']['release']['major'], '8') >= 0 {
$gpgkey_path = '/etc/pki/rpm-gpg/RPM-GPG-KEY-perfSONAR'
$gpgkey = "file://${gpgkey_path}"
exec { 'RPM-GPG-KEY-Globus':
path => '/usr/bin:/bin:/usr/sbin:/sbin',
command => "wget -qO- ${perfsonar::release_url} | rpm2cpio - | cpio -i --quiet --to-stdout .${gpgkey_path} > ${gpgkey_path}",
creates => $gpgkey_path,
before => Yumrepo['perfSONAR'],
}
} else {
$gpgkey = 'http://software.internet2.edu/rpms/RPM-GPG-KEY-perfSONAR'
$gpgkey_path = '/etc/pki/rpm-gpg/RPM-GPG-KEY-perfSONAR'
$gpgkey = "file://${gpgkey_path}"
# Extract GPG key from release RPM as the GPG keys on website don't match
# what is used to sign the RPMs
exec { 'RPM-GPG-KEY-perfSONAR':
path => '/usr/bin:/bin:/usr/sbin:/sbin',
command => "wget -qO- ${perfsonar::release_url} | rpm2cpio - | cpio -i --quiet --to-stdout .${gpgkey_path} > ${gpgkey_path}",
creates => $gpgkey_path,
before => Yumrepo['perfSONAR'],
}
yumrepo { 'perfSONAR':
descr => 'perfSONAR RPM Repository - software.internet2.edu - main',
Expand All @@ -40,7 +38,7 @@
},
key => {
'id' => '5A507954F531B92300DA2068351ED8279AFA4E0A',
'source' => 'http://downloads.perfsonar.net/debian/perfsonar-debian-official.gpg.key',
'source' => 'http://downloads.perfsonar.net/debian/perfsonar-official.gpg.key',
},
}
}
Expand Down
15 changes: 1 addition & 14 deletions metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,9 @@
}
],
"operatingsystem_support": [
{
"operatingsystem": "CentOS",
"operatingsystemrelease": [
"7"
]
},
{
"operatingsystem": "RedHat",
"operatingsystemrelease": [
"7",
"8",
"9"
]
Expand All @@ -62,12 +55,6 @@
"9"
]
},
{
"operatingsystem": "Debian",
"operatingsystemrelease": [
"10"
]
},
{
"operatingsystem": "Ubuntu",
"operatingsystemrelease": [
Expand All @@ -83,5 +70,5 @@
],
"pdk-version": "2.7.1",
"template-url": "https://github.com/treydock/pdk-templates.git#master",
"template-ref": "heads/master-0-gced7f95"
"template-ref": "heads/master-0-g5a59870"
}
28 changes: 0 additions & 28 deletions spec/acceptance/nodesets/debian-10.yml

This file was deleted.

26 changes: 0 additions & 26 deletions spec/acceptance/nodesets/el7.yml

This file was deleted.

2 changes: 1 addition & 1 deletion spec/classes/perfsonar_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

describe 'perfsonar' do
on_supported_os.each do |os, os_facts|
context "on #{os}" do
context "when #{os}" do
let(:facts) { os_facts }

it { is_expected.to compile }
Expand Down
3 changes: 2 additions & 1 deletion spec/spec_helper_acceptance.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
Dir["#{dir}/acceptance/shared_examples/**/*.rb"].sort.each { |f| require f }
require 'spec_helper_acceptance_local' if File.file?(File.join(File.dirname(__FILE__), 'spec_helper_acceptance_local.rb'))

run_puppet_install_helper
run_puppet_install_helper unless ENV['BEAKER_set'] == 'debian-12'
on hosts, 'apt install -y puppet-agent' if ENV['BEAKER_set'] == 'debian-12'
install_module_on(hosts)
install_module_dependencies_on(hosts)

Expand Down
22 changes: 0 additions & 22 deletions spec/spec_helper_acceptance_setup.rb

This file was deleted.

0 comments on commit 1cc9da6

Please sign in to comment.