[CI] Detect architecture when determining node download url (#91497)
Currently CI is setup to always download the x64 Node.js architecture. When runing builds on ARM machines we'll want to make sure the architecture matches the machine.
This commit is contained in:
parent
a99ccc27d7
commit
db6cd8665c
|
@ -56,7 +56,13 @@ export WORKSPACE="${WORKSPACE:-$PARENT_DIR}"
|
|||
nodeVersion="$(cat "$dir/.node-version")"
|
||||
nodeDir="$cacheDir/node/$nodeVersion"
|
||||
nodeBin="$nodeDir/bin"
|
||||
classifier="x64.tar.gz"
|
||||
hostArch="$(command uname -m)"
|
||||
case "${hostArch}" in
|
||||
x86_64 | amd64) nodeArch="x64" ;;
|
||||
aarch64) nodeArch="arm64" ;;
|
||||
*) nodeArch="${hostArch}" ;;
|
||||
esac
|
||||
classifier="$nodeArch.tar.gz"
|
||||
|
||||
UNAME=$(uname)
|
||||
OS="linux"
|
||||
|
|
Loading…
Reference in a new issue