Skip to content

Commit

Permalink
Fix logic to reset Slurm accounting password after queue update
Browse files Browse the repository at this point in the history
Signed-off-by: Jacopo De Amicis <[email protected]>
  • Loading branch information
jdeamicis committed Apr 18, 2023
1 parent e70cff8 commit 8daa943
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,8 @@ def update_nodes_in_queue(strategy, queues)
user 'root'
group 'root'
command "#{node['cluster']['scripts_dir']}/slurm/update_slurm_database_password.sh"
not_if { ::File.exist?(node['cluster']['previous_cluster_config_path']) && !are_queues_updated? && node['cluster']['config'].dig(:Scheduling, :SlurmSettings, :Database).nil? }
# This horrible only_if guard is needed to cover all cases that trigger "generate_pcluster_slurm_settings", in the case Slurm accounting is being used
only_if { !(::File.exist?(node['cluster']['previous_cluster_config_path']) && !are_queues_updated?) && !node['cluster']['config'].dig(:Scheduling, :SlurmSettings, :Database).nil? }
end

# Generate custom Slurm settings include files
Expand Down

0 comments on commit 8daa943

Please sign in to comment.