Advertisement
twashing

NixOS User Creation Error

Apr 1st, 2015
333
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.79 KB | None | 0 0
  1. # partial contents of: /etc/nixos/configuration.nix
  2. {
  3. ...
  4. # created this nixos from this stock vagrant box: https://github.com/zimbatm/nixbox
  5. users = {
  6. extraGroups = [ { name = "vagrant"; } { name = "twashing"; } { name = "vboxsf"; } ];
  7. extraUsers = [ {
  8. description = "Vagrant User";
  9. name = "vagrant";
  10. ...
  11. }
  12. { description = "Main User";
  13. name = "user1";
  14. group = "user1";
  15. extraGroups = [ "users" "vboxsf" "wheel" "networkmanager"];
  16. home = "/home/user1";
  17. createHome = true;
  18. useDefaultShell = true;
  19. } ];
  20. };
  21. ...
  22. }
  23.  
  24. # errors when trying to rebuild environment
  25. $ sudo nixos-rebuild switch
  26.  
  27. building Nix...
  28. building the system configuration...
  29. updating GRUB 2 menu...
  30. stopping the following units: local-fs.target, network-interfaces.target, remote-fs.target
  31. activating the configuration...
  32. setting up /etc...
  33. useradd: group 'networkmanager' does not exist
  34. chpasswd: line 1: user 'user1' does not exist
  35. chpasswd: error detected, changes ignored
  36. id: user1: no such user
  37. id: user1: no such user
  38. /nix/store/1r443r7imrzl4mgc9rw1fmi9nz76j3bx-nixos-14.04.393.6593a98/activate: line 77: test: 0: unary operator expected
  39. chown: missing operand after ‘/home/user1’
  40. Try 'chown --help' for more information.
  41. /nix/store/1r443r7imrzl4mgc9rw1fmi9nz76j3bx-nixos-14.04.393.6593a98/activate: line 78: test: 0: unary operator expected
  42. chgrp: missing operand after ‘/home/user1’
  43. Try 'chgrp --help' for more information.
  44. starting the following units: default.target, getty.target, ip-up.target, local-fs.target, multi-user.target, network-interfaces.target, network.target, paths.target, remote-fs.target, slices.target, sockets.target, swap.target, timers.target
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement