Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to install on new ARM64 Ubuntu runners (update: upstream runner issue; temporary workaround found) #198

Open
Rhys-T opened this issue Jan 17, 2025 · 2 comments

Comments

@Rhys-T
Copy link

Rhys-T commented Jan 17, 2025

GitHub just opened up their new ARM64 Linux runners to free users. I was trying to switch my repo to use that instead of QEMU, but it's failing with various permission errors when it gets to the "Install Cachix" step:

Unexpected error attempting to determine if executable file exists '/home/runneradmin/.local/bin/bash': Error: EACCES: permission denied, stat '/home/runneradmin/.local/bin/bash'
Unexpected error attempting to determine if executable file exists '/home/runneradmin/.cargo/bin/bash': Error: EACCES: permission denied, stat '/home/runneradmin/.cargo/bin/bash'
Unexpected error attempting to determine if executable file exists '/home/runneradmin/.config/composer/vendor/bin/bash': Error: EACCES: permission denied, stat '/home/runneradmin/.config/composer/vendor/bin/bash'
Unexpected error attempting to determine if executable file exists '/home/runneradmin/.dotnet/tools/bash': Error: EACCES: permission denied, stat '/home/runneradmin/.dotnet/tools/bash'
$ /usr/bin/bash -c nix-env --quiet -j8 -iA cachix -f https://cachix.org/api/v1/install
$ /home/runner/.nix-profile/bin/cachix --version
cachix 1.7.5
$ /home/runner/.nix-profile/bin/cachix authtoken ***
cachix: /home/runneradmin/.config/cachix: createDirectory: permission denied (Permission denied)
/home/runner/work/_actions/cachix/cachix-action/v15/dist/main/index.js:1702
                error = new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`);
                        ^

Error: The process '/home/runner/.nix-profile/bin/cachix' failed with exit code 1
    at ExecState._setResult (/home/runner/work/_actions/cachix/cachix-action/v15/dist/main/index.js:1702:25)
    at ExecState.CheckComplete (/home/runner/work/_actions/cachix/cachix-action/v15/dist/main/index.js:1685:18)
    at ChildProcess.<anonymous> (/home/runner/work/_actions/cachix/cachix-action/v15/dist/main/index.js:1579:27)
    at ChildProcess.emit (node:events:519:28)
    at maybeClose (node:internal/child_process:1105:16)
    at ChildProcess._handle.onexit (node:internal/child_process:305:5)

I initially ran into this on the ubuntu-24.04-arm runner, and thought maybe it was a problem on that Ubuntu version,since the x86_64 jobs are using ubuntu-latest, which keeps warning me that it's going to switch to 24.04 'soon'. But I tried downgrading it to ubuntu-22.04-arm, and got the same error - and on closer examination, the ubuntu-latest ones seem to already be using 24.04, so I guess that already rolled out to my account - so that doesn't seem to be what's causing it. Only the ARM64 Linux ones are failing.

I don't actually know whether this is a cachix-action issue or a runner issue. I started here because that was the step that was showing an error, but I just found actions/runner-images#11409, which makes it sound like it might be something on the runner's end that's affecting other projects too. I'll leave this here in case anyone else is seeing this in the context of cachix-action, or in case it helps the action work around it from this end.

@Rhys-T
Copy link
Author

Rhys-T commented Jan 17, 2025

Update: Manually fixing $XDG_CONFIG_HOME for the cachix-action step like this:

    - name: Setup cachix
      uses: cachix/cachix-action@v15
      # Don't replace <YOUR_CACHIX_NAME> here!
      if: ${{ matrix.cachixName != '<YOUR_CACHIX_NAME>' }}
      with:
        name: ${{ matrix.cachixName }}
        signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
        authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
      # ↓↓↓ adding these two lines:
      env:
        XDG_CONFIG_HOME: ~/.config

seems to let it run successfully for now, though it still gets lots of Unexpected error attempting to determine if executable file exists because I haven't fixed $PATH - in fact, it gets even more of that error now since it isn't stopping. I can try fixing $PATH too, although I'll need to figure out what the correct value actually is first, but for now this at least gets things running again.

@Rhys-T Rhys-T changed the title Fails to install on new ARM64 Ubuntu runners Fails to install on new ARM64 Ubuntu runners (update: upstream runner issue; temporary workaround found) Jan 17, 2025
@Rhys-T
Copy link
Author

Rhys-T commented Jan 17, 2025

Looks like the issue I mentioned before has been closed in favor of actions/partner-runner-images#27 and actions/partner-runner-images#25.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant