Skip to content

Commit d221572

Browse files
committed
Install 64-bit Node in container, for its libraries
This is a workaround for a problem that is the same or similar to actions/checkout#334: Run actions/checkout@v4 /usr/bin/docker exec a7f94cb30b99bd1ee851270fad4768421eddecd7e8fa674f56c4f2d2d64210b6 sh -c "cat /etc/*release | grep ^ID" exec /__e/node20/bin/node: no such file or directory I had not originally noticed the `cat /etc/*release` part of that output, and had surmised that this was a subtly different problem, but it looks like it's probably exactly the same. The workaround in actions/checkout#334 (comment) is applied in this commit and seems to be working. As noted there, the absence of some 64-bit libraries in 32-bit containers prevents the (existing and already mapped) 64-bit Node.js outside the container from being run, and installing 64-bit Node.js in the container via `apt-get` (even though, in this case, it is a different version) installs the needed dependencies, letting the (existing) Node.js run. (Other problems, related to `safe.directory` protections as well as tests that are known to fail due to assertions about the size of data structures that implicitly assume 64-bit targets, do still prevent the job from succeeding. But `actions/checkout@v4`, which was failing before, seems to be working, as do the other actions.)
1 parent bb430d7 commit d221572

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -203,11 +203,9 @@ jobs:
203203
steps:
204204
- name: Prerequisites
205205
run: |
206+
dpkg --add-architecture amd64 # For 64-bit Node.js, for actions.
206207
apt-get update
207-
apt-get install --no-install-recommends -y build-essential ca-certificates cmake curl git jq libssl-dev nodejs pkgconf
208-
#mkdir -p /__e/node20/bin
209-
#ln -s /usr/bin/node /__e/node20/bin/node
210-
file /__e/node20/bin/node
208+
apt-get install --no-install-recommends -y build-essential ca-certificates cmake curl git jq libssl-dev nodejs:amd64 pkgconf
211209
- uses: actions/checkout@v4
212210
- uses: dtolnay/rust-toolchain@stable
213211
with:

0 commit comments

Comments
 (0)