vagrant-vagga 0.1.3 → 0.1.4

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1ef48114719597d97cd52206f7a0722207f19404
4
- data.tar.gz: e422a94443f7ccbd1522d5b544952d0df5203ccd
3
+ metadata.gz: d217e70c8f93017eb98b1e7c2aaca20b688ba790
4
+ data.tar.gz: 1a681a7683cee0a2e7576366f779c6cc285426e9
5
5
  SHA512:
6
- metadata.gz: 39d53670ec383ef2a54c2856637b50ff1dd9a6a77212c1222362ec5485f8fa078fbd7c09d594e940cebf2ffcfd26cce81bed44b77d7a6075a3dba800d4a1997b
7
- data.tar.gz: d20830a5fbc5dd7f834da2a35ca31abfffbc4537955a33a7874563b749a7b79bfac707b40aa3a98c4331842038f73b4600e08ede15f4d9d4dd2522b829a7c7ff
6
+ metadata.gz: e8f500f1e1b7a144d258dd13b820f3a58ecd9a0b9c037f2f39c51b4850cf6606480318bb8b7a7e36db2c4a05f72dd47340b8cf2a9a79aae91deb2101fdc0edeb
7
+ data.tar.gz: a585f000298a404d0379306f54d0b6ce83adbad2e63cc8188d5aab5167cdd89afb10ed6d618207739d57025f3bb3c3eaa3bf05e44f7178d86568db21c6ca02c0
data/README.md CHANGED
@@ -18,6 +18,7 @@ Install gem to vagrant:
18
18
  3. Install vagrant-vagga plugin
19
19
  4. You're awesome!
20
20
 
21
+ Example project: https://github.com/rrader/vagrant-vagga/tree/master/example
21
22
 
22
23
  ## Usage
23
24
 
@@ -38,9 +39,8 @@ end
38
39
  Your working directory with Vagrantfile should also contain vagga.yaml, which is implied by plugin logic.
39
40
 
40
41
  ```shell
41
- $ vagrant up
42
- ... # after it's done
43
42
  $ vagrant vagga
43
+ [... long output spinning up the VM (only first time)]
44
44
  Available commands:
45
45
  run Run app
46
46
  setup Setup application
data/example/Vagrantfile CHANGED
@@ -7,4 +7,6 @@ Vagrant.configure("2") do |config|
7
7
  config.vm.provision :vagga
8
8
 
9
9
  config.vm.network :forwarded_port, guest: 5000, host: 5000, auto_correct: false
10
+
11
+ config.vm.box_check_update = false
10
12
  end
@@ -10,23 +10,20 @@ module VagrantPlugins
10
10
 
11
11
  def execute
12
12
  args = @argv.join(' ')
13
- vagga_command = "vagga #{args}"
14
- # Workaround for ERROR:vagga::wrapper: Error executing _build: Error symlinking storage: Permission denied (os error 13)
15
- vagga_command = "sudo #{vagga_command}"
16
- command = "cd /vagrant; #{vagga_command}"
13
+ vagga_command = "/tmp/exec_vagga.sh #{args}"
17
14
 
18
15
  with_target_vms(nil, single_target: true) do |vm|
19
- @logger.info("Executing vagga command on remote machine: #{command}")
16
+ vm.action(:up)
17
+
18
+ @logger.info("Executing vagga command on remote machine: #{vagga_command}")
20
19
  ssh_opts = {extra_args: ['-q']} # make it quiet
21
- env = vm.action(:ssh_run, ssh_run_command: command, ssh_opts: ssh_opts)
20
+ env = vm.action(:ssh_run, ssh_run_command: vagga_command, ssh_opts: ssh_opts)
22
21
 
23
22
  status = env[:ssh_run_exit_status] || 0
24
23
  return status
25
24
  end
26
25
  end
27
26
 
28
-
29
-
30
27
  end
31
28
  end
32
29
  end
@@ -0,0 +1,10 @@
1
+ cd /vagrant
2
+
3
+ HOST_DIR=/vagrant/.vagga
4
+ GUEST_DIR=~vagrant/project/.vagga
5
+
6
+ test -d $HOST_DIR || mkdir $HOST_DIR
7
+ test -d $GUEST_DIR || mkdir -p $GUEST_DIR
8
+ mountpoint -q /vagrant/.vagga || sudo mount --bind $GUEST_DIR $HOST_DIR
9
+
10
+ vagga $@
@@ -10,6 +10,7 @@ module VagrantPlugins
10
10
 
11
11
  def provision
12
12
  setup_vagga
13
+ setup_exec_script
13
14
  end
14
15
 
15
16
  def setup_vagga
@@ -29,6 +30,13 @@ module VagrantPlugins
29
30
  end
30
31
  end
31
32
 
33
+ def setup_exec_script
34
+ setup_script_destination = "/tmp/exec_vagga.sh"
35
+ setup_script_path = Pathname.new("../exec_vagga.sh").expand_path(__FILE__)
36
+ @machine.communicate.upload(setup_script_path.to_s, setup_script_destination)
37
+ @machine.communicate.sudo("chmod +x %s" % setup_script_destination)
38
+ end
39
+
32
40
  end
33
41
  end
34
42
  end
@@ -11,7 +11,7 @@ fi
11
11
 
12
12
 
13
13
 
14
- VAGGA_VERSION=$(curl -s http://files.zerogw.com/vagga/latest-testing.html | sed -e 's/<[^>]*>//g' -e 's/vagga-//g' -e 's/.tar.xz//g')
14
+ VAGGA_VERSION=$(curl -s http://files.zerogw.com/vagga/latest.html | sed -e 's/<[^>]*>//g' -e 's/vagga-//g' -e 's/.tar.xz//g')
15
15
  echo "Latest Vagga version is $VAGGA_VERSION, installing..."
16
16
 
17
17
  cd /tmp
@@ -1,5 +1,5 @@
1
1
  module VagrantPlugins
2
2
  module Vagga
3
- VERSION = "0.1.3"
3
+ VERSION = "0.1.4"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-vagga
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Roman Rader
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-08-27 00:00:00.000000000 Z
11
+ date: 2015-12-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -59,6 +59,7 @@ files:
59
59
  - lib/vagrant-vagga.rb
60
60
  - lib/vagrant-vagga/command.rb
61
61
  - lib/vagrant-vagga/config.rb
62
+ - lib/vagrant-vagga/exec_vagga.sh
62
63
  - lib/vagrant-vagga/plugin.rb
63
64
  - lib/vagrant-vagga/provisioner.rb
64
65
  - lib/vagrant-vagga/setup_vagga.sh
@@ -85,7 +86,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
85
86
  version: '0'
86
87
  requirements: []
87
88
  rubyforge_project:
88
- rubygems_version: 2.4.5
89
+ rubygems_version: 2.4.5.1
89
90
  signing_key:
90
91
  specification_version: 4
91
92
  summary: Vagrant plugin to install vagga in the box