From cf8cc4d556f3e95cbe3bc39e117163d72c694e68 Mon Sep 17 00:00:00 2001 From: Himani Deshpande Date: Mon, 15 Apr 2024 13:24:02 -0400 Subject: [PATCH] [AL2023] Installing http Parser which is a dependency for supporting slurmrestd --- .../partial/_slurm_dependencies_common.rb | 7 +++++++ .../slurm_dependencies_alinux2023.rb | 18 ++++++++++++++++++ 2 files changed, 25 insertions(+) diff --git a/cookbooks/aws-parallelcluster-slurm/resources/slurm_dependencies/partial/_slurm_dependencies_common.rb b/cookbooks/aws-parallelcluster-slurm/resources/slurm_dependencies/partial/_slurm_dependencies_common.rb index 9651e141ca..a9586d21ba 100644 --- a/cookbooks/aws-parallelcluster-slurm/resources/slurm_dependencies/partial/_slurm_dependencies_common.rb +++ b/cookbooks/aws-parallelcluster-slurm/resources/slurm_dependencies/partial/_slurm_dependencies_common.rb @@ -18,4 +18,11 @@ packages dependencies action :install end unless redhat_on_docker? + + action_install_extra_dependencies +end + + +action :install_extra_dependencies do + # Do Nothing end diff --git a/cookbooks/aws-parallelcluster-slurm/resources/slurm_dependencies/slurm_dependencies_alinux2023.rb b/cookbooks/aws-parallelcluster-slurm/resources/slurm_dependencies/slurm_dependencies_alinux2023.rb index f44ac84009..21cabb3330 100644 --- a/cookbooks/aws-parallelcluster-slurm/resources/slurm_dependencies/slurm_dependencies_alinux2023.rb +++ b/cookbooks/aws-parallelcluster-slurm/resources/slurm_dependencies/slurm_dependencies_alinux2023.rb @@ -21,4 +21,22 @@ def dependencies def unsupported_dependencies # Using `sudo dnf supportinfo --pkg ` to find if packages are available %w(http-parser-devel) + # Tried replacing http-parser with below Packages ( doesnt work ) + # %w(httpcomponents-client httpcomponents-core httpcomponents-project httpd httpd-core httpd-devel httpd-filesystem httpd-manual httpd-tools) +end + + +action :install_extra_dependencies do + # Following https://slurm.schedmd.com/related_software.html#jwt for Installing Http-parser + bash 'Install http-parser' do + user 'root' + group 'root' + code <<-HTTP_PARSER + set -e + git clone --depth 1 --single-branch -b v2.9.4 https://github.com/nodejs/http-parser.git http_parser + cd http_parser + make + make install + HTTP_PARSER + end end