From 102df2f98195436e5743472111a623f6cfffa660 Mon Sep 17 00:00:00 2001 From: Cam Cope Date: Mon, 17 Aug 2015 14:23:55 -0700 Subject: [PATCH] make /tmp a tmpfs --- lib/vagrant-lxc/action/boot.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/vagrant-lxc/action/boot.rb b/lib/vagrant-lxc/action/boot.rb index 5a956356..8fc71135 100644 --- a/lib/vagrant-lxc/action/boot.rb +++ b/lib/vagrant-lxc/action/boot.rb @@ -20,6 +20,9 @@ def call(env) config.customize 'mount.entry', '/sys/fs/pstore sys/fs/pstore none bind,optional 0 0' end + # Make /tmp a tmpfs to prevent init scripts from nuking synced folders mounted in here + config.customize 'mount.entry', 'tmpfs tmp tmpfs nodev,nosuid,size=2G 0 0' + env[:ui].info I18n.t("vagrant_lxc.messages.starting") env[:machine].provider.driver.start(config.customizations)