vagrant-hostmanager 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile CHANGED
@@ -1,7 +1,4 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
+ gem 'vagrant', :git => 'git://github.com/mitchellh/vagrant.git', :tag => 'v1.1.5'
3
4
  gemspec
4
-
5
- group :development do
6
- gem 'vagrant', github: 'mitchellh/vagrant', tag: 'v1.1.2'
7
- end
data/Rakefile ADDED
@@ -0,0 +1,12 @@
1
+ require 'bundler/gem_helper'
2
+
3
+ # Change to the directory of this file.
4
+ Dir.chdir(File.expand_path("../", __FILE__))
5
+
6
+ namespace :gem do
7
+ Bundler::GemHelper.install_tasks
8
+ end
9
+
10
+ task :test do
11
+ sh 'bash test/test.sh'
12
+ end
@@ -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('locales/en.yml', HostManager.source_root)
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
 
@@ -1,5 +1,5 @@
1
1
  module VagrantPlugins
2
2
  module HostManager
3
- VERSION = '0.0.1'
3
+ VERSION = '0.0.2'
4
4
  end
5
5
  end
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'
@@ -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.1
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-03-27 00:00:00.000000000 Z
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
- - bin/build.sh
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
data/bin/build.sh DELETED
@@ -1,5 +0,0 @@
1
- rm *.gem
2
- gem uninstall -a vagrant-hostmanager
3
- gem build *.gemspec
4
- gem install *.gem
5
- vagrant plugin install vagrant-hostmanager