vagrant-ansible 0.0.3 → 0.0.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.
- data/README.md +2 -0
- data/Vagrantfile.sample +2 -0
- data/lib/vagrant-ansible/provisioner.rb +16 -2
- metadata +8 -8
data/README.md
CHANGED
@@ -71,6 +71,8 @@ You will notice that the VM is automatically created, and nginx-ubuntu playbook
|
|
71
71
|
|
72
72
|
Have a look at your Vagrantfile, it will look like this:
|
73
73
|
|
74
|
+
require 'vagrant-ansible'
|
75
|
+
|
74
76
|
Vagrant::Config.run do |config|
|
75
77
|
config.vm.box = "oneiric32_base"
|
76
78
|
config.vm.box_url = "http://files.travis-ci.org/boxes/bases/oneiric32_base.box"
|
data/Vagrantfile.sample
CHANGED
@@ -3,7 +3,7 @@ require 'tempfile'
|
|
3
3
|
module Vagrant
|
4
4
|
module Provisioners
|
5
5
|
class Ansible < Base
|
6
|
-
VERSION = '0.0.
|
6
|
+
VERSION = '0.0.4'
|
7
7
|
include Util::SafeExec
|
8
8
|
|
9
9
|
class Config < Vagrant::Config::Base
|
@@ -14,7 +14,7 @@ module Vagrant
|
|
14
14
|
attr_accessor :sudo
|
15
15
|
|
16
16
|
def initialize
|
17
|
-
|
17
|
+
@options = []
|
18
18
|
end
|
19
19
|
|
20
20
|
def validate(env, errors)
|
@@ -26,6 +26,19 @@ module Vagrant
|
|
26
26
|
errors.add(I18n.t("vagrant.provisioners.ansible.no_hosts"))
|
27
27
|
end
|
28
28
|
end
|
29
|
+
|
30
|
+
# Allows for assigning one to many options to pass to ansible-playbook.
|
31
|
+
def options=(*opts)
|
32
|
+
@options = if opts.is_a? String
|
33
|
+
[opts]
|
34
|
+
else
|
35
|
+
opts
|
36
|
+
end
|
37
|
+
end
|
38
|
+
|
39
|
+
def options
|
40
|
+
@options
|
41
|
+
end
|
29
42
|
end
|
30
43
|
|
31
44
|
def self.config_class
|
@@ -64,6 +77,7 @@ module Vagrant
|
|
64
77
|
|
65
78
|
options << "--ask-sudo-pass" if config.ask_sudo_pass
|
66
79
|
options << "--sudo" if config.sudo
|
80
|
+
options = options + config.options unless config.options.empty?
|
67
81
|
|
68
82
|
cmd = (%w(ansible-playbook) << options << config.playbook).flatten
|
69
83
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vagrant-ansible
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-08-
|
12
|
+
date: 2012-08-22 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: vagrant
|
16
|
-
requirement: &
|
16
|
+
requirement: &22328900 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *22328900
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: rdoc
|
27
|
-
requirement: &
|
27
|
+
requirement: &22327820 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ~>
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: '3.10'
|
33
33
|
type: :development
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *22327820
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: hoe
|
38
|
-
requirement: &
|
38
|
+
requirement: &22326620 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ~>
|
@@ -43,7 +43,7 @@ dependencies:
|
|
43
43
|
version: '3.0'
|
44
44
|
type: :development
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *22326620
|
47
47
|
description: Develop & test your ansible playbooks with Vagrant
|
48
48
|
email:
|
49
49
|
- git@dsander.de
|