vagrant-hostmanager 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Gemfile +1 -4
- data/Rakefile +12 -0
- data/lib/vagrant-hostmanager/plugin.rb +6 -9
- data/lib/vagrant-hostmanager/version.rb +1 -1
- data/test/Vagrantfile +2 -0
- data/{bin → test}/test.sh +2 -1
- metadata +5 -10
- data/bin/build.sh +0 -5
data/Gemfile
CHANGED
data/Rakefile
ADDED
@@ -13,24 +13,21 @@ module VagrantPlugins
|
|
13
13
|
action_hook(:hostmanager_up, :machine_action_up) do |hook|
|
14
14
|
setup_i18n
|
15
15
|
setup_logging
|
16
|
-
|
17
|
-
# TODO use hook.append when defect is fixed within vagrant
|
18
|
-
hook.after(ProviderVirtualBox::Action::Boot, Action::UpdateHostsFile)
|
16
|
+
hook.append(Action::UpdateHostsFile)
|
19
17
|
end
|
20
18
|
|
21
19
|
action_hook(:hostmanger_destroy, :machine_action_destroy) do |hook|
|
22
20
|
setup_i18n
|
23
21
|
setup_logging
|
24
|
-
|
25
|
-
# TODO use hook.append when defect is fixed within vagrant
|
26
|
-
hook.after(
|
27
|
-
ProviderVirtualBox::Action::DestroyUnusedNetworkInterfaces,
|
28
|
-
Action::UpdateHostsFile)
|
22
|
+
hook.append(Action::UpdateHostsFile)
|
29
23
|
end
|
30
24
|
|
31
25
|
def self.setup_i18n
|
32
|
-
I18n.load_path << File.expand_path(
|
26
|
+
I18n.load_path << File.expand_path(
|
27
|
+
'locales/en.yml',
|
28
|
+
HostManager.source_root)
|
33
29
|
I18n.reload!
|
30
|
+
|
34
31
|
Helpers::Translator.plugin_namespace = 'vagrant_hostmanager'
|
35
32
|
end
|
36
33
|
|
data/test/Vagrantfile
CHANGED
@@ -1,6 +1,8 @@
|
|
1
1
|
# -*- mode: ruby -*-
|
2
2
|
# vi: set ft=ruby :
|
3
3
|
|
4
|
+
Vagrant.require_plugin('vagrant-hostmanager')
|
5
|
+
|
4
6
|
Vagrant.configure('2') do |config|
|
5
7
|
config.vm.box = 'precise64-chef11.2'
|
6
8
|
config.vm.box_url = 'https://opscode-vm.s3.amazonaws.com/vagrant/opscode_ubuntu-12.04_chef-11.2.0.box'
|
data/{bin → test}/test.sh
RENAMED
@@ -1,4 +1,5 @@
|
|
1
1
|
cd test
|
2
|
+
|
2
3
|
vagrant up
|
3
4
|
echo "[server1] /etc/hosts file:"
|
4
5
|
vagrant ssh server1 -c 'cat /etc/hosts'
|
@@ -8,5 +9,5 @@ vagrant destroy server1 -f
|
|
8
9
|
echo "[server2] /etc/hosts file:"
|
9
10
|
vagrant ssh server2 -c 'cat /etc/hosts'
|
10
11
|
vagrant destroy server2 -f
|
11
|
-
cd ..
|
12
12
|
|
13
|
+
cd ..
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vagrant-hostmanager
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-04-04 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
14
|
description: A Vagrant plugin that manages the /etc/hosts file within a multi-machine
|
15
15
|
environment
|
@@ -23,8 +23,7 @@ files:
|
|
23
23
|
- Gemfile
|
24
24
|
- LICENSE.txt
|
25
25
|
- README.md
|
26
|
-
-
|
27
|
-
- bin/test.sh
|
26
|
+
- Rakefile
|
28
27
|
- lib/vagrant-hostmanager.rb
|
29
28
|
- lib/vagrant-hostmanager/action/update_hosts_file.rb
|
30
29
|
- lib/vagrant-hostmanager/errors.rb
|
@@ -33,6 +32,7 @@ files:
|
|
33
32
|
- lib/vagrant-hostmanager/version.rb
|
34
33
|
- locales/en.yml
|
35
34
|
- test/Vagrantfile
|
35
|
+
- test/test.sh
|
36
36
|
- vagrant-hostmanager.gemspec
|
37
37
|
homepage:
|
38
38
|
licenses: []
|
@@ -46,18 +46,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
46
46
|
- - ! '>='
|
47
47
|
- !ruby/object:Gem::Version
|
48
48
|
version: '0'
|
49
|
-
segments:
|
50
|
-
- 0
|
51
|
-
hash: 2205065072905881096
|
52
49
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
53
50
|
none: false
|
54
51
|
requirements:
|
55
52
|
- - ! '>='
|
56
53
|
- !ruby/object:Gem::Version
|
57
54
|
version: '0'
|
58
|
-
segments:
|
59
|
-
- 0
|
60
|
-
hash: 2205065072905881096
|
61
55
|
requirements: []
|
62
56
|
rubyforge_project:
|
63
57
|
rubygems_version: 1.8.23
|
@@ -67,3 +61,4 @@ summary: A Vagrant plugin that manages the /etc/hosts file within a multi-machin
|
|
67
61
|
environment
|
68
62
|
test_files:
|
69
63
|
- test/Vagrantfile
|
64
|
+
- test/test.sh
|