nixos/nix-ld: replace variable with sessionVariables

I tried to execute the command over ssh (without login). But got an
error about shared libraries.

Error reproduction:

```bash
ssh <user>@<host> env | grep NIX_LD_LIBRARY_PATH
```

Replacing shell variables with PAM variables solves this problem.
This commit is contained in:
name_snrl 2024-10-31 10:28:23 +05:00
parent 8d81a29e4a
commit 6c289ca719

View File

@ -34,7 +34,7 @@ in
environment.pathsToLink = [ "/share/nix-ld" ];
environment.variables = {
environment.sessionVariables = {
NIX_LD = "/run/current-system/sw/share/nix-ld/lib/ld.so";
NIX_LD_LIBRARY_PATH = "/run/current-system/sw/share/nix-ld/lib";
};