Skip to content

Instantly share code, notes, and snippets.

@merlinstardust
Created March 10, 2016 16:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save merlinstardust/535c1c055f15dfbdabc0 to your computer and use it in GitHub Desktop.
Save merlinstardust/535c1c055f15dfbdabc0 to your computer and use it in GitHub Desktop.
Mounts Meteor local directories within Vagrant so apps can run
config.vm.provision ".meteor mounting", type: "shell", run: "always" do |shell|
shell.privileged = false
shell.args = "'#{app_name}'"
shell.inline = <<-SHELL
echo "Mounting .meteor/local directories"
for directory in /$1/*; do
if [ -d $directory/.meteor ]; then
mkdir -p $directory/.meteor/local
mkdir -p /home/vagrant$directory/.meteor/local
sudo mount --bind /home/vagrant$directory/.meteor/local $directory/.meteor/local
fi
done
echo "Directories created"
SHELL
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment