From ec693f2c59d48a4318ef50c24b1ea2af6132cdd7 Mon Sep 17 00:00:00 2001 From: Evgeni Golov Date: Tue, 14 May 2024 10:14:35 +0200 Subject: [PATCH 1/2] use NodeJS 18.x on EL9 CI nodes --- puppet/modules/jenkins_node/manifests/unittests.pp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/puppet/modules/jenkins_node/manifests/unittests.pp b/puppet/modules/jenkins_node/manifests/unittests.pp index 2db37eb4a..6889799ae 100644 --- a/puppet/modules/jenkins_node/manifests/unittests.pp +++ b/puppet/modules/jenkins_node/manifests/unittests.pp @@ -71,8 +71,9 @@ # nodejs/npm for JavaScript tests if $facts['os']['family'] == 'RedHat' { + $nodejs_version = $facts['os']['release']['major'] ? { '8' => '14', default => '18' } class { 'nodejs': - repo_url_suffix => '14.x', + repo_url_suffix => "${nodejs_version}.x", nodejs_package_ensure => latest, npm_package_name => false, } -> Package <| provider == 'npm' |> From fb346c0e5a2c8566fa9e591797ff41f6a30ec500 Mon Sep 17 00:00:00 2001 From: Evgeni Golov Date: Fri, 17 May 2024 14:36:32 +0200 Subject: [PATCH 2/2] Use NodeJS 18 from DNF module instead of NodeSource --- puppet/Puppetfile | 2 +- puppet/modules/jenkins_node/manifests/unittests.pp | 9 ++++----- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/puppet/Puppetfile b/puppet/Puppetfile index 32d77aa38..76c67c8cc 100644 --- a/puppet/Puppetfile +++ b/puppet/Puppetfile @@ -13,7 +13,7 @@ mod 'puppet/extlib', '7.0.0' mod 'puppet/jenkins', '5.0.0' mod 'puppet/letsencrypt', '11.0.0' mod 'puppet/mosquitto', '2.1.0' -mod 'puppet/nodejs', '10.0.0' +mod 'puppet/nodejs', '11.0.0' mod 'puppet/pbuilder', '2.0.0' mod 'puppet/redis', '11.0.0' mod 'puppet/selinux', '4.1.0' diff --git a/puppet/modules/jenkins_node/manifests/unittests.pp b/puppet/modules/jenkins_node/manifests/unittests.pp index 6889799ae..001898f19 100644 --- a/puppet/modules/jenkins_node/manifests/unittests.pp +++ b/puppet/modules/jenkins_node/manifests/unittests.pp @@ -70,12 +70,11 @@ stdlib::ensure_packages(['python3-virtualenv']) # nodejs/npm for JavaScript tests - if $facts['os']['family'] == 'RedHat' { - $nodejs_version = $facts['os']['release']['major'] ? { '8' => '14', default => '18' } + if $facts['os']['family'] == 'RedHat' and $facts['os']['release']['major'] == '9' { class { 'nodejs': - repo_url_suffix => "${nodejs_version}.x", - nodejs_package_ensure => latest, - npm_package_name => false, + repo_version => '18', + repo_class => 'nodejs::repo::dnfmodule', + npm_package_name => false, } -> Package <| provider == 'npm' |> package { 'bower':