Skip to content

Commit e0d5616

Browse files
hanwen-clusterhanwen-pcluste
authored andcommitted
Remove unused Munge SysV init logic
The Munge installation is already based on systemd. The SysV Init logic is no longer used. We forgot to remove this logic when we dropped support for Amazon Linux 1 When running kitchen tests on Docker, munge on some OSes still uses SysV. Therefore, we skip some `service` resource execution. We take the kitchen tests on EC2 instance as the golden standard. This is consistent with what we've been doing (i.e. We have been skip some `service` resource for other packages) Signed-off-by: Hanwen <[email protected]>
1 parent 050e8cd commit e0d5616

File tree

5 files changed

+3
-602
lines changed

5 files changed

+3
-602
lines changed

cookbooks/aws-parallelcluster-slurm/libraries/helpers.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ def enable_munge_service
6565
action %i(enable start)
6666
retries 5
6767
retry_delay 10
68-
end
68+
end unless on_docker?
6969
end
7070

7171
def setup_munge_head_node

cookbooks/aws-parallelcluster-slurm/resources/munge/partial/_munge_actions.rb

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@
4848
action_purge_packages
4949
action_download_source_code
5050
action_compile_and_install
51-
action_update_init_script
5251
action_set_user_and_group
5352
action_create_required_directories
5453
}
@@ -93,19 +92,6 @@
9392
end
9493
end
9594

96-
action :update_init_script do
97-
# Updated munge init script for Amazon Linux
98-
template '/etc/init.d/munge' do
99-
source 'munge/munge-init.erb'
100-
cookbook 'aws-parallelcluster-slurm'
101-
owner 'root'
102-
group 'root'
103-
variables(munge_user: munge_user,
104-
munge_group: munge_group)
105-
mode '0755'
106-
end
107-
end
108-
10995
action :set_user_and_group do
11096
# Setup munge group
11197
group munge_group do

cookbooks/aws-parallelcluster-slurm/resources/munge_key_manager.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def restart_munge_service
2929
action :restart
3030
retries 5
3131
retry_delay 10
32-
end
32+
end unless on_docker?
3333
end
3434

3535
def enable_munge_service
@@ -38,7 +38,7 @@ def enable_munge_service
3838
action :enable
3939
retries 5
4040
retry_delay 10
41-
end
41+
end unless on_docker?
4242
end
4343

4444
def share_munge_key_to_dir(shared_dir)

0 commit comments

Comments
 (0)