summary refs log tree commit diff
diff options
context:
space:
mode:
authorGraham Christensen <graham@grahamc.com>2018-02-07 17:43:34 -0500
committerGitHub <noreply@github.com>2018-02-07 17:43:34 -0500
commit7fb90db6960832cf16fa806d6e59fc6ab3cd0456 (patch)
tree23b5e27936d9303974ead0484cd1a7b0901934ca
parentdc8975215406b255de7926bf41098151192f73ce (diff)
parent0525e823929dd9116aaba9f194ef629c83f80d81 (diff)
downloadnixlib-7fb90db6960832cf16fa806d6e59fc6ab3cd0456.tar
nixlib-7fb90db6960832cf16fa806d6e59fc6ab3cd0456.tar.gz
nixlib-7fb90db6960832cf16fa806d6e59fc6ab3cd0456.tar.bz2
nixlib-7fb90db6960832cf16fa806d6e59fc6ab3cd0456.tar.lz
nixlib-7fb90db6960832cf16fa806d6e59fc6ab3cd0456.tar.xz
nixlib-7fb90db6960832cf16fa806d6e59fc6ab3cd0456.tar.zst
nixlib-7fb90db6960832cf16fa806d6e59fc6ab3cd0456.zip
Merge pull request #34710 from markus1189/doc-vm-login
docs: Explain how to login into built vm
-rw-r--r--nixos/doc/manual/installation/changing-config.xml18
1 files changed, 15 insertions, 3 deletions
diff --git a/nixos/doc/manual/installation/changing-config.xml b/nixos/doc/manual/installation/changing-config.xml
index 75df307a1b7c..4db9020b9606 100644
--- a/nixos/doc/manual/installation/changing-config.xml
+++ b/nixos/doc/manual/installation/changing-config.xml
@@ -70,9 +70,21 @@ $ ./result/bin/run-*-vm
 </screen>
 
 The VM does not have any data from your host system, so your existing
-user accounts and home directories will not be available.  You can
-forward ports on the host to the guest.  For instance, the following
-will forward host port 2222 to guest port 22 (SSH):
+user accounts and home directories will not be available unless you
+have set <literal>mutableUsers = false</literal>.  Another way is to
+temporarily add the following to your configuration:
+
+<screen>
+users.extraUsers.your-user.initialPassword = "test"  
+</screen>
+
+<emphasis>Important:</emphasis> delete the $hostname.qcow2 file if you
+have started the virtual machine at least once without the right
+users, otherwise the changes will not get picked up.
+
+You can forward ports on the host to the guest.  For
+instance, the following will forward host port 2222 to guest port 22
+(SSH):
 
 <screen>
 $ QEMU_NET_OPTS="hostfwd=tcp::2222-:22" ./result/bin/run-*-vm