-
Notifications
You must be signed in to change notification settings - Fork 4
/
vagrantfile
53 lines (41 loc) · 1.65 KB
/
vagrantfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Copyright 2016 Wipro Limited, NIIT Limited
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# This code is written by Prateek Reddy Yammanuru, Shiva Manognya Kandikuppa, Uday Kumar Mydam, Nirup TNL, Sandeep Reddy G, Deepak Kumar
vagrant_cache_server = "172.23.238.253"
# Detect the current OS. node on windows needs some symlink magic to work.
module OS
def OS.windows?
(/cygwin|mswin|mingw|bccwin|wince|emx/ =~ RUBY_PLATFORM) != nil
end
end
Vagrant.configure(2) do |config|
config.vm.box = "stackroute/barebones-node"
config.vm.box_url = "http://#{vagrant_cache_server}/vagrant/boxes/stackroute-barebones-node.box"
config.vm.hostname = 'stackroute-node'
# Map the guest os port 8080 to host os port 8080
config.vm.network "forwarded_port", guest: 8585, host: 9595
if OS.windows?
# enable symlinks between the host/gust filesystems
config.vm.provider "virtualbox" do |vb|
vb.customize ["setextradata", :id, "VBoxInternal2/SharedFoldersEnableSymlinksCreate/v-root", "1"]
end
# Setup the softlinks
config.vm.provision :puppet do |puppet|
puppet.manifest_file = "windows.pp"
end
end
end