From ac64be720e6c158557c1427cd5cd6b9a8eaeac00 Mon Sep 17 00:00:00 2001
From: Martin Potthast <martin.potthast@uni-weimar.de>
Date: Fri, 22 Feb 2013 16:43:56 +0100
Subject: [PATCH] Vagrant now attempts to mount NFS on both Linux and Darwin.
 Updated documentation accordingly.

---
 Vagrantfile     |  3 ++-
 docs/VAGRANT.md | 10 ++++++++++
 2 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/Vagrantfile b/Vagrantfile
index ab165e419..3e3ffe6bd 100644
--- a/Vagrantfile
+++ b/Vagrantfile
@@ -25,7 +25,8 @@ Vagrant::Config.run do |config|
   config.vm.forward_port 3000, 4000
   config.vm.forward_port 1080, 4080 # Mailcatcher
 
-  nfs_setting = RUBY_PLATFORM =~ /darwin/ ? true : false
+  nfs_setting = (RUBY_PLATFORM =~ /darwin/ or
+                 RUBY_PLATFORM =~ /linux/) ? true : false
   config.vm.share_folder("v-root", "/vagrant", ".", :nfs => nfs_setting)
 
   chef_cookbooks_path = ["chef/cookbooks"]
diff --git a/docs/VAGRANT.md b/docs/VAGRANT.md
index d8a3f7511..20dccee30 100644
--- a/docs/VAGRANT.md
+++ b/docs/VAGRANT.md
@@ -26,6 +26,16 @@ Vagrant will prompt you for your admin password. This is so it can mount your lo
 
 (The first time you do this, it will take a while as it downloads the VM image and installs it. Go grab a coffee.)
 
+**Note to OSX/Linux users**: Vagrant will mount your local files via an NFS share. Therefore, make sure that NFS is installed or else you'll receive the error message:
+
+```
+Mounting NFS shared folders failed. This is most often caused by the NFS
+client software not being installed on the guest machine. Please verify
+that the NFS client software is properly installed, and consult any resources
+specific to the linux distro you're using for more information on how to
+do this.
+```
+
 Once the machine has booted up, you can shell into it by typing:
 
 ```