From e84c681e382f8a84d9da1e0f744d12a47a749716 Mon Sep 17 00:00:00 2001
From: Michael Adam <obnox@samba.org>
Date: Thu, 8 Jan 2015 00:59:04 +0100
Subject: [PATCH] fedora: add option MASK_TMP to prevent overmounting /tmp with
 tmpfs

this is important for use with vagrant-cachier
---
 fedora/install-extras.sh | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/fedora/install-extras.sh b/fedora/install-extras.sh
index c7c7671..0d22b41 100755
--- a/fedora/install-extras.sh
+++ b/fedora/install-extras.sh
@@ -19,3 +19,11 @@ PACKAGES=(vim curl wget man-db bash-completion ca-certificates sudo openssh-serv
 
 utils.lxc.attach yum update -y
 utils.lxc.attach yum install ${PACKAGES[*]} -y
+
+
+MASK_TMP=${MASK_TMP:-0}
+
+if [ $MASK_TMP -eq 1 ]; then
+	# don't overmount /tmp with tmpfs: important for lxc-cachier
+	utils.lxc.attach systemctl mask tmp.mount
+fi