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

Adding general tips of how to troubleshoot the instalation of single user nix installer #1

Open
PedroRegisPOAR opened this issue Apr 9, 2021 · 3 comments

Comments

@PedroRegisPOAR
Copy link
Contributor

PedroRegisPOAR commented Apr 9, 2021

TODO:

Checking environment variables

env
env | grep 'some_env_var name'
declare -px > env.sh
source env.sh

https://stackoverflow.com/a/39119103

The /tmp thing

The ~/tmp and/or /tmp:

security_model=mapped-xattr

Refs.:

## FIX for running out of space / tmp, which is used for building
fileSystems."/nix/.rw-store" = {
  fsType = "tmpfs";
  # options = [ "mode=0755" ];
  options = [ "mode=0755" "nosuid" "nodev" "relatime" "size=14G" ];
  neededForBoot = true;
};

From: https://githubmemory.com/repo/colemickens/nixcfg/issues/3

Remote builders

{ nix.trustedUsers = [ "@wheel" ]; } # or specific user
@PedroRegisPOAR
Copy link
Contributor Author

PedroRegisPOAR commented Jun 9, 2021

Using the CLI

nix flake update --override-input nixpkgs nixpkgs/84aa23742f6c72501f9cc209f29c438766f5352d
nix \
flake \
update \
--override-input nixpkgs github:NixOS/nixpkgs/nixos-21.11

@PedroRegisPOAR
Copy link
Contributor Author

TODO: take a look in that.

However, if nix has to build a derivation, it has to spin up a builder... And builders run in a user namespace with uids and gids mapped and significantly less permissions. That builder is what's spitting out that error.
From: NixOS/nixpkgs#67465 (comment)

@PedroRegisPOAR
Copy link
Contributor Author

TODO:

$ nix build github:nix-community/nix-installers/93907b1b4a34b4391bc3e776a410213669f64074#deb
$ ls -al result 
lrwxrwxrwx 1 pedro pedro 68 jul  6 13:04 result -> /nix/store/a6li3c1in0cia6a4nsmy4nnvh3b550hq-nix-multi-user-2.9.1.deb

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