aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Lutomirski <luto@kernel.org>2016-01-07 17:22:56 -0800
committerAndy Lutomirski <luto@kernel.org>2016-01-07 17:22:56 -0800
commit4c51a3dac79036ce783eccf65f4a381fdf914797 (patch)
treed52fdf095e1110f745cb9bc459fc1f929fb330e5
parent0d61d88ffff6d2670d3c2ee1d123a1cd67fd2cba (diff)
downloadvirtme-4c51a3dac79036ce783eccf65f4a381fdf914797.tar.gz
virtme-init: Set a HOME directory
Everything works better if HOME points somewhere writable. Signed-off-by: Andy Lutomirski <luto@kernel.org>
-rwxr-xr-xvirtme/guest/virtme-init4
1 files changed, 4 insertions, 0 deletions
diff --git a/virtme/guest/virtme-init b/virtme/guest/virtme-init
index 238c482..da71a9a 100755
--- a/virtme/guest/virtme-init
+++ b/virtme/guest/virtme-init
@@ -172,6 +172,10 @@ for p in "${!virtme_@}"; do export -n "$p"; done
echo "virtme-init: console is $consdev"
+# Set up a basic environment
+install -d -m 0755 /tmp/roothome
+export HOME=/tmp/roothome
+
# Bring up a functioning shell on the console. This is a bit magical:
# We have no controlling terminal because we're attached to a fake
# console device (probably something like /dev/console), which can't