aboutsummaryrefslogtreecommitdiff
path: root/gnu/system/examples/vm-image.tmpl
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2019-04-27 15:07:31 +0200
committerLudovic Courtès <ludo@gnu.org>2019-04-27 15:08:18 +0200
commit6e0521eeede6bd06bc083073145413a04771aad3 (patch)
tree24b88a22e87ea29ddee7be27ba51bada5af424cc /gnu/system/examples/vm-image.tmpl
parent68400dfafa7b6e85cd2d03d2b2b531df2af28bc1 (diff)
downloadguix-6e0521eeede6bd06bc083073145413a04771aad3.tar
guix-6e0521eeede6bd06bc083073145413a04771aad3.tar.gz
vm-image: Allow for password-less sudo.
* gnu/system/examples/vm-image.tmpl (sudoers-file): New field.
Diffstat (limited to 'gnu/system/examples/vm-image.tmpl')
-rw-r--r--gnu/system/examples/vm-image.tmpl6
1 files changed, 6 insertions, 0 deletions
diff --git a/gnu/system/examples/vm-image.tmpl b/gnu/system/examples/vm-image.tmpl
index c8a5ee066b..95cfcb6865 100644
--- a/gnu/system/examples/vm-image.tmpl
+++ b/gnu/system/examples/vm-image.tmpl
@@ -57,6 +57,12 @@ accounts.\x1b[0m
"audio" "video")))
%base-user-accounts))
+ ;; Our /etc/sudoers file. Since 'guest' initially has an empty password,
+ ;; allow for password-less sudo.
+ (sudoers-file (plain-file "sudoers" "\
+root ALL=(ALL) ALL
+%wheel ALL=NOPASSWD: ALL\n"))
+
(packages (append (list font-bitstream-vera nvi wget)
%base-packages))