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

Support Slurm 24.05.x #63

Merged
merged 5 commits into from
Dec 26, 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
10 changes: 7 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ jobs:
fail-fast: false
matrix:
include:
- ruby: 2.7.7
- ruby: 2.7.8
puppet: 7
fixtures: .fixtures.yml
allow_failure: false
- ruby: 3.2.2
- ruby: 3.2.3
puppet: 8
fixtures: .fixtures.yml
allow_failure: false
Expand Down Expand Up @@ -56,10 +56,13 @@ jobs:
puppet:
- "puppet7"
- "puppet8"
slurm_version:
- "23.11.10"
- "24.05.4"
env:
BUNDLE_WITHOUT: development:release
BEAKER_debug: true
name: ${{ matrix.puppet }} ${{ matrix.set }}
name: ${{ matrix.puppet }} ${{ matrix.set }} (slurm=${{ matrix.slurm_version }})
steps:
- name: Enable IPv6 on docker
run: |
Expand All @@ -86,3 +89,4 @@ jobs:
env:
BEAKER_PUPPET_COLLECTION: ${{ matrix.puppet }}
BEAKER_set: ${{ matrix.set }}
BEAKER_slurm_version: ${{ matrix.slurm_version }}
10 changes: 9 additions & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,15 @@ Style/TernaryParentheses:
Style/TrailingCommaInArguments:
Description: Prefer always trailing comma on multiline argument lists. This makes
diffs, and re-ordering nicer.
EnforcedStyleForMultiline: comma
EnforcedStyleForMultiline: consistent_comma
Style/TrailingCommaInArrayLiteral:
Description: Prefer always trailing comma on multiline argument lists. This makes
diffs, and re-ordering nicer.
EnforcedStyleForMultiline: consistent_comma
Style/TrailingCommaInHashLiteral:
Description: Prefer always trailing comma on multiline argument lists. This makes
diffs, and re-ordering nicer.
EnforcedStyleForMultiline: consistent_comma
Style/SymbolArray:
Description: Using percent style obscures symbolic intent of array's contents.
EnforcedStyle: brackets
Expand Down
11 changes: 11 additions & 0 deletions .sync.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
---
.github/workflows/ci.yaml:
acceptance_name: '${{ matrix.puppet }} ${{ matrix.set }} (slurm=${{ matrix.slurm_version }})'
acceptance_matrix:
set:
- ---el7
Expand All @@ -11,6 +12,16 @@
puppet:
- puppet7
- puppet8
slurm_version:
- '23.11.10'
- '24.05.4'
#acceptance_includes:
# - set: el8
# puppet: puppet7
# slurm_version: '24.05.4'
# - set: el9
# puppet: puppet7
# slurm_version: '24.05.4'
.gitlab-ci.yml:
delete: true
.rubocop.yml:
Expand Down
4 changes: 2 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,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
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Manage SLURM.

### Supported Versions of SLURM

This module is designed to work with SLURM 22.05.x, 23.02.x and 23.11.x.
This module is designed to work with SLURM 23.11.x and 24.05.x.

| SLURM Version | SLURM Puppet module versions |
| ----------------- | -----------------------------|
Expand All @@ -36,6 +36,7 @@ This module is designed to work with SLURM 22.05.x, 23.02.x and 23.11.x.
| 21.08.x & 22.05.x | 2.x |
| 23.02.x | 3.x |
| 23.11.x | 4.x |
| 23.11.x - 24.05.x | 5.x |

## Usage

Expand Down
1 change: 0 additions & 1 deletion manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
'CliFilterPlugins' => undef,
'CommunicationParameters' => undef,
'CompleteWait' => '0',
'CoreSpecPlugin' => undef,
'CpuFreqDef' => undef,
'CpuFreqGovernors' => 'OnDemand,Performance,UserSpace',
'CredType' => 'cred/munge',
Expand Down
3 changes: 3 additions & 0 deletions manifests/partition.pp
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
# @param deny_qos
# @param default_time
# @param disable_root_jobs
# @param exclusive_topo
# @param exclusive_user
# @param grace_time
# @param hidden
Expand Down Expand Up @@ -64,6 +65,7 @@
Optional[Variant[String[1], Array[String[1]]]] $deny_qos = undef,
Optional[String[1]] $default_time = undef,
Optional[Slurm::YesNo] $disable_root_jobs = undef,
Optional[Slurm::YesNo] $exclusive_topo = undef,
Optional[Slurm::YesNo] $exclusive_user = undef,
Optional[Variant[String[1], Integer]] $grace_time = undef,
Optional[Slurm::YesNo] $hidden = undef,
Expand Down Expand Up @@ -112,6 +114,7 @@
'DenyAccounts' => $deny_accounts,
'DenyQos' => $deny_qos,
'DisableRootJobs' => $disable_root_jobs,
'ExclusiveTopo' => $exclusive_topo,
'ExclusiveUser' => $exclusive_user,
'GraceTime' => $grace_time,
'Hidden' => $hidden,
Expand Down
4 changes: 2 additions & 2 deletions metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
},
{
"name": "treydock/munge",
"version_requirement": ">= 1.1.0 <6.0.0"
"version_requirement": ">= 1.1.0 <7.0.0"
},
{
"name": "puppet/systemd",
Expand Down Expand Up @@ -113,5 +113,5 @@
],
"pdk-version": "2.7.1",
"template-url": "https://github.com/treydock/pdk-templates.git#master",
"template-ref": "heads/master-0-g52b1622"
"template-ref": "heads/master-0-gd2de99e"
}
8 changes: 4 additions & 4 deletions spec/acceptance/shared_examples/common_install.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ def packages
'libslurm-perl',
'libpmi0',
'libpmi2-0',
'slurm-client'
'slurm-client',
],
slurmd: 'slurmd',
slurmctld: 'slurmctld',
slurmdbd: 'slurmdbd',
slurmrestd: nil
slurmrestd: nil,
}
else
{
Expand All @@ -24,12 +24,12 @@ def packages
'slurm-example-configs',
'slurm-perlapi',
'slurm-libpmi',
'slurm-pam_slurm'
'slurm-pam_slurm',
],
slurmd: 'slurm-slurmd',
slurmctld: 'slurm-slurmctld',
slurmdbd: 'slurm-slurmdbd',
slurmrestd: 'slurm-slurmrestd'
slurmrestd: 'slurm-slurmrestd',
}
end
end
Expand Down
2 changes: 1 addition & 1 deletion spec/classes/slurm_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
slurmdbd: slurmdbd,
database: database,
slurmrestd: slurmrestd,
install_method: 'package'
install_method: 'package',
}
end
let(:params) { default_params.merge(param_override) }
Expand Down
8 changes: 4 additions & 4 deletions spec/defines/slurm_conf_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@
on_supported_os(supported_os: [
{
'operatingsystem' => 'RedHat',
'operatingsystemrelease' => ['7']
}
'operatingsystemrelease' => ['7'],
},
]).each do |_os, os_facts|
let(:facts) { os_facts }
let(:title) { 'ascend' }
let(:params) do
{
configs: {
'ClusterName' => 'ascend',
'SlurmctldHost' => 'ascend-slurm01.example.com'
}
'SlurmctldHost' => 'ascend-slurm01.example.com',
},
}
end

Expand Down
4 changes: 2 additions & 2 deletions spec/defines/slurm_gres_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
on_supported_os(supported_os: [
{
'operatingsystem' => 'RedHat',
'operatingsystemrelease' => ['7']
}
'operatingsystemrelease' => ['7'],
},
]).each do |_os, os_facts|
let(:facts) { os_facts }
let(:title) { 'gpu' }
Expand Down
4 changes: 2 additions & 2 deletions spec/defines/slurm_job_container_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
on_supported_os(supported_os: [
{
'operatingsystem' => 'RedHat',
'operatingsystemrelease' => ['7']
}
'operatingsystemrelease' => ['7'],
},
]).each do |_os, os_facts|
let(:facts) { os_facts }
let(:title) { '/dev/shm' }
Expand Down
4 changes: 2 additions & 2 deletions spec/defines/slurm_nodeset_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
on_supported_os(supported_os: [
{
'operatingsystem' => 'RedHat',
'operatingsystemrelease' => ['7']
}
'operatingsystemrelease' => ['7'],
},
]).each do |_os, os_facts|
let(:facts) { os_facts }
let(:title) { 'test' }
Expand Down
30 changes: 15 additions & 15 deletions spec/defines/slurm_spank_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
on_supported_os(supported_os: [
{
'operatingsystem' => 'RedHat',
'operatingsystemrelease' => ['7']
}
'operatingsystemrelease' => ['7'],
},
]).each do |_os, os_facts|
let(:facts) { os_facts }
let(:title) { 'x11' }
Expand All @@ -20,7 +20,7 @@
it do
is_expected.to contain_package('SLURM SPANK x11 package').only_with(ensure: 'installed',
name: 'slurm-spank-x11',
notify: ['Service[slurmd]'])
notify: ['Service[slurmd]'],)
end

it do
Expand All @@ -37,8 +37,8 @@

it do
verify_fragment_contents(catalogue, 'plugstack.conf-x11', [
'required x11.so'
])
'required x11.so',
],)
end
end

Expand All @@ -53,8 +53,8 @@

it do
verify_fragment_contents(catalogue, 'plugstack.conf-x11', [
'optional x11.so ssh_cmd=ssh helpertask_cmd=2>/tmp/log'
])
'optional x11.so ssh_cmd=ssh helpertask_cmd=2>/tmp/log',
],)
end
end

Expand All @@ -63,8 +63,8 @@

it do
verify_fragment_contents(catalogue, 'plugstack.conf-x11', [
'optional x11.so ssh_cmd=ssh helpertask_cmd=2>/tmp/log'
])
'optional x11.so ssh_cmd=ssh helpertask_cmd=2>/tmp/log',
],)
end
end

Expand All @@ -73,8 +73,8 @@

it do
verify_fragment_contents(catalogue, 'plugstack.conf-x11', [
'optional x11.so helpertask_cmd=2>/tmp/log ssh_cmd=ssh'
])
'optional x11.so helpertask_cmd=2>/tmp/log ssh_cmd=ssh',
],)
end
end

Expand All @@ -95,18 +95,18 @@
'conf' => '/etc/auks/auks.conf',
'default' => 'enabled',
'spankstackcred' => 'no',
'minimum_uid' => '0'
'minimum_uid' => '0',
},
package_name: 'auks-slurm'
package_name: 'auks-slurm',
}
end

it { is_expected.to contain_package('SLURM SPANK auks package').with_name('auks-slurm') }

it do
verify_fragment_contents(catalogue, 'plugstack.conf-auks', [
'required auks.so conf=/etc/auks/auks.conf default=enabled spankstackcred=no minimum_uid=0'
])
'required auks.so conf=/etc/auks/auks.conf default=enabled spankstackcred=no minimum_uid=0',
],)
end
end

Expand Down
Loading