vagrant-kaigara 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1e5fb579fc12e80bc10b03729f40ae9bb891d3bb
4
- data.tar.gz: 39f80f4604b68e1c842119fc6b7a43e8aa903d0a
3
+ metadata.gz: 18c24a498c99159a8d2eb32931f1fa6620c994c2
4
+ data.tar.gz: 59c24f5d501e0089fe9a9fadadbd26f05806749c
5
5
  SHA512:
6
- metadata.gz: 2b52711ad1f2487d36701a9d069356206b335bbd316f753819ee1ffa3d895ed8a1d22d6a5c5137afc78b51cf7fa737dc784eb1fa59e5423e33f41a126c2d8006
7
- data.tar.gz: bff6ea19b676c04397a6ad71150a281ac82e662ad13b835e61e9e54fc93d2a5a44a0cfa533efd49e4c4a2f5e73355e31b282fb58aa09696c53fa96dcb617f3d1
6
+ metadata.gz: c610ad813ff57d3acc35d1770226c25827d9547e59f30368d3dd6b8af0e3fcb50f58b042ba3280b5015bfd315ac5f05f017878a097130153cfc93bcc066141ce
7
+ data.tar.gz: cbb2af91debdac7a7d2beb4a2524bbdf4be91d73422b95385836fabedbbc9ab82ae50f9a1782daf3cf6a24b41507e87a7ea03adb209e6e539264d45d7293fbe2
@@ -10,7 +10,7 @@ module VagrantPlugins
10
10
  @machine.ui.info("Ruby is already installed")
11
11
  else
12
12
  @machine.ui.info("Installing Ruby...")
13
- @machine.ui.info("curl http://mirror.kaigara.org/scripts/kairb.sh | bash /dev/stdin")
13
+ action("curl http://mirror.kaigara.org/scripts/kairb.sh | bash /dev/stdin")
14
14
  end
15
15
 
16
16
  if kaigara_installed?
@@ -27,7 +27,7 @@ module VagrantPlugins
27
27
  # Execute a command at vm
28
28
  def action(command, opts = {})
29
29
  @machine.communicate.tap do |comm|
30
- comm.execute(command, { error_key: :ssh_bad_exit_status_muted, sudo: true }.merge(opts) ) do |type, data|
30
+ comm.execute("source /etc/profile; #{command}", { error_key: :ssh_bad_exit_status_muted, sudo: true }.merge(opts) ) do |type, data|
31
31
  Thread.new do
32
32
  handle_comm(type, data)
33
33
  end
@@ -53,11 +53,15 @@ module VagrantPlugins
53
53
  end
54
54
 
55
55
  def ruby_installed?
56
- @machine.communicate.test('ruby -v', sudo: true)
56
+ test('test -f /opt/kaigara') && test('ruby -v')
57
57
  end
58
58
 
59
59
  def kaigara_installed?
60
- @machine.communicate.test('kaish', sudo: true)
60
+ test('kaish')
61
+ end
62
+
63
+ def test(t)
64
+ @machine.communicate.test(t, sudo: true)
61
65
  end
62
66
  end
63
67
  end
@@ -1,5 +1,5 @@
1
1
  module VagrantPlugins
2
2
  module Kaigara
3
- VERSION = "0.0.4"
3
+ VERSION = "0.0.5"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-kaigara
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dmitry Koval
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-07-05 00:00:00.000000000 Z
11
+ date: 2016-07-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake