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

Cachix action v14 + v13 failing since Jan 15 #168

Closed
ryanswrt opened this issue Jan 17, 2024 · 4 comments
Closed

Cachix action v14 + v13 failing since Jan 15 #168

ryanswrt opened this issue Jan 17, 2024 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@ryanswrt
Copy link

ryanswrt commented Jan 17, 2024

On 15 Jan my existing cachix action setup failed with

Post job cleanup.
Cachix: push
  /home/runner/work/_actions/cachix/cachix-action/v13/dist/main/push-paths.sh cachix  REDACTED  REDACTED
  /home/runner/work/_actions/cachix/cachix-action/v13/dist/main/push-paths.sh: line 14: cachix: command not found
  Error: Action failed with error: Error: The process '/home/runner/work/_actions/cachix/cachix-action/v13/dist/main/push-paths.sh' failed with exit code 127

I tried updating the cachix and install-nix actions to the latest version, however it still seems to fail with some kind of issue in the cachix binary.

Post job cleanup.
Cachix: push
  [2024-01-17 03:48:27][Info] Starting Cachix Daemon
  [2024-01-17 03:48:27][Info] Configuration:
  PID: 2823
  Socket: /home/runner/work/_temp/cachix-daemon-2o0Jvh/daemon.sock
  Workers: 8
  Cache name: REDACTED
  Cache URI: REDACTED
  Cache public keys: [PUBLIC KEY HERE]
  Cache is public: False
  Compression: ZSTD
  Error: Action failed with error: Error: Unable to locate executable file: /home/runner/.nix-profile/bin/cachix. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.

I am using magic-nix-cache too so that i get github-local caches for a bit of increased speed, don't know if that is interfering somehow

@domenkozar domenkozar added the bug Something isn't working label Jan 17, 2024
@domenkozar
Copy link
Member

Smells like #144 again.

@sandydoo
Copy link
Member

@ryanswrt, does your workflow have any nix profile installs?

Nix seems to be nuking the existing nix-env profile when converting it. Still looking into why this is happening.

@sandydoo
Copy link
Member

We're deploying a fix to https://cachix.org/api/v1/install.

The action uses nix-env to install cachix. This keeps us compatible with both nix-env and nix profile workflows. Unfortunately, there are some subtle differences in how these two commands handle derivations with multiple outputs, e.g. $out and $bin. nix-env handles this by installing both outputs, but nix profile ignores the $bin output when migrating the profile. We had a workaround for this that was recently removed.

@sandydoo
Copy link
Member

We've updated the derivations served by https://cachix.org/api/v1/install and https://cachix.org/api/v1/install/v1.7 to work around the issue with nix profile. This should now be fixed. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants