vagrant-yaybu 0.0.4 → 0.0.5

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.
@@ -82,6 +82,8 @@ module Vagrant
82
82
  attr_accessor :include
83
83
 
84
84
  def initialize
85
+ super
86
+
85
87
  @yay = ""
86
88
  @python = "python"
87
89
  @searchpath = []
@@ -89,16 +91,19 @@ module Vagrant
89
91
  end
90
92
  end
91
93
 
94
+ def self.config_class
95
+ Config
96
+ end
97
+
92
98
  def bootstrap
93
- vm.ssh.execute do |ssh|
94
- begin
95
- ssh.sudo!("which yaybu", :error_class => YaybuError, :_key => :yaybu_not_detected, :binary => "yaybu")
96
- rescue
97
- env.ui.info "Yaybu not found so attempting to install it"
98
- ssh.sudo!("apt-get update")
99
- ssh.sudo!("apt-get install python-setuptools -y")
100
- ssh.sudo!("easy_install Yaybu")
101
- end
99
+ ssh = env[:vm].channel
100
+ begin
101
+ ssh.sudo("which yaybu", :error_class => YaybuError, :_key => :yaybu_not_detected, :binary => "yaybu")
102
+ rescue
103
+ env[:ui].info "Yaybu not found so attempting to install it"
104
+ ssh.sudo("apt-get update")
105
+ ssh.sudo("apt-get install python-setuptools -y")
106
+ ssh.sudo("easy_install Yaybu")
102
107
  end
103
108
  end
104
109
 
@@ -126,10 +131,10 @@ module Vagrant
126
131
  bootstrap
127
132
 
128
133
  deployment_script = TemplateRenderer.render_string($deploy_script, {
129
- :ssh_host => vm.env.config.ssh.host,
130
- :ssh_user => vm.env.config.ssh.username,
131
- :ssh_port => vm.ssh.port,
132
- :private_key_path => vm.env.config.ssh.private_key_path,
134
+ :ssh_host => env[:vm].ssh.info[:host],
135
+ :ssh_user => env[:vm].ssh.info[:username],
136
+ :ssh_port => env[:vm].ssh.info[:port],
137
+ :private_key_path => env[:vm].ssh.info[:private_key_path],
133
138
  :yay => config.yay,
134
139
  :searchpath => config.searchpath,
135
140
  :includes => config.include,
@@ -140,7 +145,7 @@ module Vagrant
140
145
  io.close_write
141
146
 
142
147
  while line = io.gets do
143
- env.ui.info("#{line}")
148
+ env[:ui].info("#{line}")
144
149
  end
145
150
  end
146
151
  end
@@ -1,5 +1,5 @@
1
1
  module Vagrant
2
2
  module Yaybu
3
- VERSION = "0.0.4"
3
+ VERSION = "0.0.5"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-yaybu
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: