|
1 |
| -# -*- mode: ruby -*- |
2 |
| -# vi: set ft=ruby : |
3 |
| - |
4 |
| -Vagrant::Config.run do |config| |
5 |
| - # All Vagrant configuration is done here. The most common configuration |
6 |
| - # options are documented and commented below. For a complete reference, |
7 |
| - # please see the online documentation at vagrantup.com. |
8 |
| - |
9 |
| - # Every Vagrant virtual environment requires a box to build off of. |
10 |
| - config.vm.box = "phpdevbox" |
11 |
| - |
12 |
| - # The url from where the 'config.vm.box' box will be fetched if it |
13 |
| - # doesn't already exist on the user's system. |
14 |
| - # config.vm.box_url = "http://domain.com/path/to/above.box" |
15 |
| - |
16 |
| - # Boot with a GUI so you can see the screen. (Default is headless) |
17 |
| - # config.vm.boot_mode = :gui |
18 |
| - |
19 |
| - # Assign this VM to a host-only network IP, allowing you to access it |
20 |
| - # via the IP. Host-only networks can talk to the host machine as well as |
21 |
| - # any other machines on the same network, but cannot be accessed (through this |
22 |
| - # network interface) by any external networks. |
23 |
| - # config.vm.network :hostonly, "192.168.33.10" |
24 |
| - |
25 |
| - # Assign this VM to a bridged network, allowing you to connect directly to a |
26 |
| - # network using the host's network device. This makes the VM appear as another |
27 |
| - # physical device on your network. |
28 |
| - # config.vm.network :bridged |
29 |
| - |
30 |
| - # Forward a port from the guest to the host, which allows for outside |
31 |
| - # computers to access the VM, whereas host only networking does not. |
32 |
| - config.vm.forward_port 80, 8080 #apache |
33 |
| - config.vm.forward_port 81, 8181 #nginx |
34 |
| - config.vm.forward_port 27017, 27017 #mongodb |
35 |
| - config.vm.forward_port 3306, 3306 #mysql |
36 |
| - |
37 |
| - # Share an additional folder to the guest VM. The first argument is |
38 |
| - # an identifier, the second is the path on the guest to mount the |
39 |
| - # folder, and the third is the path on the host to the actual folder. |
40 |
| - # config.vm.share_folder "v-data", "/vagrant_data", "../data" |
41 |
| - |
42 |
| - # Enable provisioning with Puppet stand alone. Puppet manifests |
43 |
| - # are contained in a directory path relative to this Vagrantfile. |
44 |
| - # You will need to create the manifests directory and a manifest in |
45 |
| - # the file precise64.pp in the manifests_path directory. |
46 |
| - # |
47 |
| - # An example Puppet manifest to provision the message of the day: |
48 |
| - # |
49 |
| - # # group { "puppet": |
50 |
| - # # ensure => "present", |
51 |
| - # # } |
52 |
| - # # |
53 |
| - # # File { owner => 0, group => 0, mode => 0644 } |
54 |
| - # # |
55 |
| - # # file { '/etc/motd': |
56 |
| - # # content => "Welcome to your Vagrant-built virtual machine! |
57 |
| - # # Managed by Puppet.\n" |
58 |
| - # # } |
59 |
| - # |
60 |
| - config.vm.provision :puppet do |puppet| |
61 |
| - puppet.manifests_path = "puppet/manifests" |
62 |
| - puppet.module_path = "puppet/modules" |
63 |
| - puppet.options = ['--verbose'] |
64 |
| - end |
65 |
| - |
66 |
| - # Enable provisioning with chef solo, specifying a cookbooks path, roles |
67 |
| - # path, and data_bags path (all relative to this Vagrantfile), and adding |
68 |
| - # some recipes and/or roles. |
69 |
| - # |
70 |
| - # config.vm.provision :chef_solo do |chef| |
71 |
| - # chef.cookbooks_path = "../my-recipes/cookbooks" |
72 |
| - # chef.roles_path = "../my-recipes/roles" |
73 |
| - # chef.data_bags_path = "../my-recipes/data_bags" |
74 |
| - # chef.add_recipe "mysql" |
75 |
| - # chef.add_role "web" |
76 |
| - # |
77 |
| - # # You may also specify custom JSON attributes: |
78 |
| - # chef.json = { :mysql_password => "foo" } |
79 |
| - # end |
80 |
| - |
81 |
| - # Enable provisioning with chef server, specifying the chef server URL, |
82 |
| - # and the path to the validation key (relative to this Vagrantfile). |
83 |
| - # |
84 |
| - # The Opscode Platform uses HTTPS. Substitute your organization for |
85 |
| - # ORGNAME in the URL and validation key. |
86 |
| - # |
87 |
| - # If you have your own Chef Server, use the appropriate URL, which may be |
88 |
| - # HTTP instead of HTTPS depending on your configuration. Also change the |
89 |
| - # validation key to validation.pem. |
90 |
| - # |
91 |
| - # config.vm.provision :chef_client do |chef| |
92 |
| - # chef.chef_server_url = "https://api.opscode.com/organizations/ORGNAME" |
93 |
| - # chef.validation_key_path = "ORGNAME-validator.pem" |
94 |
| - # end |
95 |
| - # |
96 |
| - # If you're using the Opscode platform, your validator client is |
97 |
| - # ORGNAME-validator, replacing ORGNAME with your organization name. |
98 |
| - # |
99 |
| - # IF you have your own Chef Server, the default validation client name is |
100 |
| - # chef-validator, unless you changed the configuration. |
101 |
| - # |
102 |
| - # chef.validation_client_name = "ORGNAME-validator" |
103 |
| - |
104 |
| - # allow symlinks in vm |
105 |
| - config.vm.customize ["setextradata", :id, "VBoxInternal2/SharedFoldersEnableSymlinksCreate/v-root", "1"] |
106 |
| -end |
| 1 | +# -*- mode: ruby -*- |
| 2 | +# vi: set ft=ruby : |
| 3 | + |
| 4 | +Vagrant::Config.run do |config| |
| 5 | + # All Vagrant configuration is done here. The most common configuration |
| 6 | + # options are documented and commented below. For a complete reference, |
| 7 | + # please see the online documentation at vagrantup.com. |
| 8 | + |
| 9 | + # Every Vagrant virtual environment requires a box to build off of. |
| 10 | + config.vm.box = "phpdevbox" |
| 11 | + |
| 12 | + # The url from where the 'config.vm.box' box will be fetched if it |
| 13 | + # doesn't already exist on the user's system. |
| 14 | + # config.vm.box_url = "http://domain.com/path/to/above.box" |
| 15 | + |
| 16 | + # Boot with a GUI so you can see the screen. (Default is headless) |
| 17 | + # config.vm.boot_mode = :gui |
| 18 | + |
| 19 | + # Assign this VM to a host-only network IP, allowing you to access it |
| 20 | + # via the IP. Host-only networks can talk to the host machine as well as |
| 21 | + # any other machines on the same network, but cannot be accessed (through this |
| 22 | + # network interface) by any external networks. |
| 23 | + # config.vm.network :hostonly, "192.168.33.10" |
| 24 | + |
| 25 | + # Assign this VM to a bridged network, allowing you to connect directly to a |
| 26 | + # network using the host's network device. This makes the VM appear as another |
| 27 | + # physical device on your network. |
| 28 | + # config.vm.network :bridged |
| 29 | + |
| 30 | + # Forward a port from the guest to the host, which allows for outside |
| 31 | + # computers to access the VM, whereas host only networking does not. |
| 32 | + config.vm.forward_port 80, 8080 #apache |
| 33 | + config.vm.forward_port 81, 8181 #nginx |
| 34 | + config.vm.forward_port 27017, 27017 #mongodb |
| 35 | + config.vm.forward_port 3306, 3306 #mysql |
| 36 | + |
| 37 | + # Share an additional folder to the guest VM. The first argument is |
| 38 | + # an identifier, the second is the path on the guest to mount the |
| 39 | + # folder, and the third is the path on the host to the actual folder. |
| 40 | + # config.vm.share_folder "v-data", "/vagrant_data", "../data" |
| 41 | + |
| 42 | + # Enable provisioning with Puppet stand alone. Puppet manifests |
| 43 | + # are contained in a directory path relative to this Vagrantfile. |
| 44 | + # You will need to create the manifests directory and a manifest in |
| 45 | + # the file precise64.pp in the manifests_path directory. |
| 46 | + # |
| 47 | + # An example Puppet manifest to provision the message of the day: |
| 48 | + # |
| 49 | + # # group { "puppet": |
| 50 | + # # ensure => "present", |
| 51 | + # # } |
| 52 | + # # |
| 53 | + # # File { owner => 0, group => 0, mode => 0644 } |
| 54 | + # # |
| 55 | + # # file { '/etc/motd': |
| 56 | + # # content => "Welcome to your Vagrant-built virtual machine! |
| 57 | + # # Managed by Puppet.\n" |
| 58 | + # # } |
| 59 | + # |
| 60 | + config.vm.provision :puppet do |puppet| |
| 61 | + puppet.manifests_path = "puppet/manifests" |
| 62 | + puppet.module_path = "puppet/modules" |
| 63 | + puppet.options = ['--verbose'] |
| 64 | + end |
| 65 | + |
| 66 | + # Enable provisioning with chef solo, specifying a cookbooks path, roles |
| 67 | + # path, and data_bags path (all relative to this Vagrantfile), and adding |
| 68 | + # some recipes and/or roles. |
| 69 | + # |
| 70 | + # config.vm.provision :chef_solo do |chef| |
| 71 | + # chef.cookbooks_path = "../my-recipes/cookbooks" |
| 72 | + # chef.roles_path = "../my-recipes/roles" |
| 73 | + # chef.data_bags_path = "../my-recipes/data_bags" |
| 74 | + # chef.add_recipe "mysql" |
| 75 | + # chef.add_role "web" |
| 76 | + # |
| 77 | + # # You may also specify custom JSON attributes: |
| 78 | + # chef.json = { :mysql_password => "foo" } |
| 79 | + # end |
| 80 | + |
| 81 | + # Enable provisioning with chef server, specifying the chef server URL, |
| 82 | + # and the path to the validation key (relative to this Vagrantfile). |
| 83 | + # |
| 84 | + # The Opscode Platform uses HTTPS. Substitute your organization for |
| 85 | + # ORGNAME in the URL and validation key. |
| 86 | + # |
| 87 | + # If you have your own Chef Server, use the appropriate URL, which may be |
| 88 | + # HTTP instead of HTTPS depending on your configuration. Also change the |
| 89 | + # validation key to validation.pem. |
| 90 | + # |
| 91 | + # config.vm.provision :chef_client do |chef| |
| 92 | + # chef.chef_server_url = "https://api.opscode.com/organizations/ORGNAME" |
| 93 | + # chef.validation_key_path = "ORGNAME-validator.pem" |
| 94 | + # end |
| 95 | + # |
| 96 | + # If you're using the Opscode platform, your validator client is |
| 97 | + # ORGNAME-validator, replacing ORGNAME with your organization name. |
| 98 | + # |
| 99 | + # IF you have your own Chef Server, the default validation client name is |
| 100 | + # chef-validator, unless you changed the configuration. |
| 101 | + # |
| 102 | + # chef.validation_client_name = "ORGNAME-validator" |
| 103 | + |
| 104 | + # allow symlinks in vm |
| 105 | + config.vm.customize ["setextradata", :id, "VBoxInternal2/SharedFoldersEnableSymlinksCreate/v-root", "1"] |
| 106 | +end |
0 commit comments