Skip to content

Commit 522e41b

Browse files
rathbomaclaude
andcommitted
Fix Node.js installation in ARM64 workflows
Use the newer NodeSource repository setup method with GPG keys. The old setup script wasn't working properly in the ARM64 container. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
1 parent 21013ff commit 522e41b

File tree

2 files changed

+18
-6
lines changed

2 files changed

+18
-6
lines changed

.github/workflows/electron-arm64.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,19 @@ jobs:
2323
# Install dependencies in the container
2424
install: |
2525
apt-get update -q -y
26-
apt-get install -q -y curl build-essential python3 git \
27-
libgtk-3-dev libnotify-dev libnss3 libxss1 libasound2 \
28-
libx11-xcb1 libxcb-dri3-0 libdrm2 libgbm1 libasound2t64 || apt-get install -q -y libasound2
26+
apt-get install -q -y ca-certificates curl gnupg build-essential python3 git \
27+
libgtk-3-dev libnotify-dev libnss3 libxss1 \
28+
libx11-xcb1 libxcb-dri3-0 libdrm2 libgbm1
29+
# Try to install libasound2t64, fallback to libasound2
30+
apt-get install -q -y libasound2t64 || apt-get install -q -y libasound2
2931
# Install Node.js 20 (for Electron build)
30-
curl -fsSL https://deb.nodesource.com/setup_20.x | bash -
32+
mkdir -p /etc/apt/keyrings
33+
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
34+
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
35+
apt-get update -q -y
3136
apt-get install -q -y nodejs
37+
node --version
38+
npm --version
3239
3340
# Run build and tests
3441
run: |

.github/workflows/nodejs-arm64.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,15 @@ jobs:
2323
# Install dependencies in the container
2424
install: |
2525
apt-get update -q -y
26-
apt-get install -q -y curl build-essential python3 git
26+
apt-get install -q -y ca-certificates curl gnupg build-essential python3 git
2727
# Install Node.js 22
28-
curl -fsSL https://deb.nodesource.com/setup_22.x | bash -
28+
mkdir -p /etc/apt/keyrings
29+
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg
30+
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_22.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list
31+
apt-get update -q -y
2932
apt-get install -q -y nodejs
33+
node --version
34+
npm --version
3035
3136
# Run build and tests
3237
run: |

0 commit comments

Comments
 (0)