LnL7 / nix-darwin

nix modules for darwin
MIT License
3.18k stars 456 forks source link

Installation gotcha... /etc/nix/nix.conf #458

Open dfee opened 2 years ago

dfee commented 2 years ago

I've installed nix on 3 computers (2 Intel and 1 ARM MBP). Each time I've run into an installation error because /etc/nix/nix.conf exists with the following contents from my installation of nix:

build-users-group = nixbld

the error i get (when running the installer)...

setting up /etc...
error: not linking environment.etc."nix/nix.conf" because /etc/nix/nix.conf already exists, skipping...
existing file has unknown content ff08c12813680da98c4240328f828647b67a65ba7aa89c022bd8072cba862cf1, move and activate again to apply

moving /etc/nix/nix.conf to /etc/nix/nix.conf.bkup, and I get a successful installation, with the following contents in /etc/nix/nix.conf:

# WARNING: this file is generated from the nix.* options in
# your NixOS configuration, typically
# /etc/nixos/configuration.nix.  Do not edit it!
build-users-group = nixbld

max-jobs = auto
cores = 0
sandbox = false

substituters = https://cache.nixos.org/
trusted-substituters = 
trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
require-sigs = true
trusted-users = root
allowed-users = *
lockejan commented 2 years ago

duplicate of #149