Open stephen-huan opened 1 month ago
I guess first thought is that the switch-to-configuration program, regardless of if you're using the new implementation or not, is only responsible for the last parts of the output above. The git errors look like errors happening during the build of your config's config.system.build.toplevel
. I can't see anything here that would cause a difference based on switch-to-configuration implementation. Have you tried using the --use-remote-sudo
when calling nixos-rebuild instead of calling with sudo?
I guess first thought is that the switch-to-configuration program, regardless of if you're using the new implementation or not, is only responsible for the last parts of the output above. The git errors look like errors happening during the build of your config's
config.system.build.toplevel
. I can't see anything here that would cause a difference based on switch-to-configuration implementation.
All I can say is I've definitely not gotten these warnings with the perl script and got the warnings as soon as I switched (https://github.com/stephen-huan/nixos-config/commit/12ae15d21e460e2fb2b6532c03964b236697e5d2) ~a month ago.
Have you tried using the
--use-remote-sudo
when calling nixos-rebuild instead of calling with sudo?
nixos-rebuild switch --use-remote-sudo
works, sudo nixos-rebuild switch --use-remote-sudo
works, and sudo sudo nixos-rebuild switch --use-remote-sudo
gives the warnings again.
To be clear, I'm not looking for a workaround---I can just not run nixos-rebuild
with two sudo
's, and even if I do, the update still happens successfully anyways. I just figured I might as well report an inconsistency I was observing.
Thanks for the pointers. I'll see if I can track the error down to something more concrete, and update this issue if I do.
Describe the bug
With
system.switch.enableNg = true
, runningsudo sudo nixos-rebuild switch
(note the twosudo
's) givesNote that the system is still successfully updated from the master branch of my personal configuration.
Running
sudo nixos-rebuild switch
(only one sudo) givesas expected. Equivalently, the warnings occur if one is root (
sudo su
) and runssudo nixos-rebuild switch
and does not occur ifnixos-rebuild switch
is ran as root. I'm not sure why there is a difference betweensudo sudo
andsudo
.Steps To Reproduce
The quirks in my setup that could be contributing are
/keep
. This means my configuration is technically on a different filesystem than/
(which is a tmpfs). That is,df -h
showsstat ~/.config/home-manager/.git
showsExpected behavior
Wasn't sure if this was worth reporting but the original PR says
and I do not get the warning with the perl script.
Notify maintainers
@jmbaur (sorry for the noise if there's something simple I'm missing!)
Metadata
"x86_64-linux"
Linux 6.6.35, NixOS, 24.11 (Vicuna), 24.11.20240622.a71e967
no
(I am on a multi-user setup)yes
nix-env (Nix) 2.18.2
not found
(my nixpkgs version is a71e967ef3694799d0c418c98332f7ff4cc5f6af).Add a :+1: reaction to issues you find important.