From 9024f7631c6746488c538edbf52dadc1eca86f6e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ulises=20Gasc=C3=B3n?= Date: Sun, 1 Sep 2024 01:07:57 +0200 Subject: [PATCH] feat: add Java 17 for Jenkins Related https://github.com/nodejs/build/issues/3686 --- orka/templates/macos-13-arm-test.pkr.hcl | 16 ++++++++++++---- orka/templates/macos-13-intel-test.pkr.hcl | 13 +++++++++++-- 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/orka/templates/macos-13-arm-test.pkr.hcl b/orka/templates/macos-13-arm-test.pkr.hcl index 430e8af11..7445fd31b 100644 --- a/orka/templates/macos-13-arm-test.pkr.hcl +++ b/orka/templates/macos-13-arm-test.pkr.hcl @@ -64,7 +64,7 @@ build { "/opt/homebrew/bin/brew doctor || true" ] } - // Install dependencies using Homebrew. + // Install dependencies for build and test. provisioner "shell" { inline = [ "echo 'Installing packages using Homebrew...'", @@ -72,13 +72,21 @@ build { "/opt/homebrew/bin/brew install git automake bash libtool cmake python ccache" ] } - + // Install Java 17 for Jenkins. + provisioner "shell" { + inline = [ + "echo 'Installing JRE...'", + "eval \"$(/opt/homebrew/bin/brew shellenv)\"", + "/opt/homebrew/bin/brew install --cask temurin@17", + ] + } // Print the version of the installed packages. provisioner "shell" { inline = [ "echo 'Printing the version of the installed packages...'", - "eval \"$(/usr/local/bin/brew shellenv)\"", - "/opt/homebrew/bin/brew list --versions" + "eval \"$(/opt/homebrew/bin/brew shellenv)\"", + "/opt/homebrew/bin/brew list --versions", + "java -version" ] } } \ No newline at end of file diff --git a/orka/templates/macos-13-intel-test.pkr.hcl b/orka/templates/macos-13-intel-test.pkr.hcl index c3ad21572..80957df71 100644 --- a/orka/templates/macos-13-intel-test.pkr.hcl +++ b/orka/templates/macos-13-intel-test.pkr.hcl @@ -63,7 +63,7 @@ build { "/usr/local/bin/brew doctor || true" ] } - // Install dependencies using Homebrew. + // Install dependencies for build and test. provisioner "shell" { inline = [ "echo 'Installing packages using Homebrew...'", @@ -71,12 +71,21 @@ build { "/usr/local/bin/brew install git automake bash libtool cmake python ccache" ] } + // Install Java 17 for Jenkins. + provisioner "shell" { + inline = [ + "echo 'Installing JRE...'", + "eval \"$(/usr/local/bin/brew shellenv)\"", + "/usr/local/bin/brew install --cask temurin@17", + ] + } // Print the version of the installed packages. provisioner "shell" { inline = [ "echo 'Printing the version of the installed packages...'", "eval \"$(/usr/local/bin/brew shellenv)\"", - "/usr/local/bin/brew list --versions" + "/usr/local/bin/brew list --versions", + "java -version" ] } } \ No newline at end of file