vagrant-bolt 0.1.1 → 0.1.2

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
  SHA256:
3
- metadata.gz: ac8831c37dc6fd0c0e551015f54ba1cb85e0c0ef6d264d5767429e84d7ad2a45
4
- data.tar.gz: 63ee832a3448361a91433d54d89484f1a3916f349bac2313602e478b1e4840f3
3
+ metadata.gz: 990a16a93781adb1b28be300b0ea508f803ff3c0bc9be52116248e32de342b37
4
+ data.tar.gz: 7040a8261b3361000aa348c33655ef305450d143a0242258ba8e43a02038e027
5
5
  SHA512:
6
- metadata.gz: d12d5842671a0c5d49991d96d00ec6ff1e4242b22b64a49e5634ec341bb6168e96d7fcd56193d622301748eeb1a7039d4cbf79bfc45751cb80d4e9fa394c63bf
7
- data.tar.gz: b85ae2521973b7c65c3be2aa0539ea78a6a6baf5728dd43eb4573ac5d77d9d9aaee0a491ba4d5326ef828a61f90890b954c87d8accec5ab12c181ad73db788e0
6
+ metadata.gz: 4e69a5dc28b0091ade803b1f2e8fa350b9684b4ef55ebfa7d52b3a02fd8bbabafacff0a54bf9522cdd71a0c65d30de4ec596fbc0c4044c57545e16a1b72e494d
7
+ data.tar.gz: 5ba5d41497a76f67ae8092edf8928e584331813d9103852193008fdd40456b03b23999e05ae03e1a18d7e4cf35417f87a1f6cafd2b498ed872c973b5f36f9d28
@@ -1,7 +1,15 @@
1
1
  # Change Log
2
2
 
3
- ## [0.1.1](https://github.com/oscar-stack/vagrant-bolt/tree/0.1.1) (2019-07-01)
4
- [Full Changelog](https://github.com/oscar-stack/vagrant-bolt/compare/v0.1.0...0.1.1)
3
+ ## [v0.1.2](https://github.com/oscar-stack/vagrant-bolt/tree/v0.1.2) (2019-10-17)
4
+ [Full Changelog](https://github.com/oscar-stack/vagrant-bolt/compare/v0.1.1...v0.1.2)
5
+
6
+ **Merged pull requests:**
7
+
8
+ - Fix the bolt path issue and create a release [\#11](https://github.com/oscar-stack/vagrant-bolt/pull/11) ([jarretlavallee](https://github.com/jarretlavallee))
9
+ - Fix changelog version tag [\#10](https://github.com/oscar-stack/vagrant-bolt/pull/10) ([jarretlavallee](https://github.com/jarretlavallee))
10
+
11
+ ## [v0.1.1](https://github.com/oscar-stack/vagrant-bolt/tree/v0.1.1) (2019-07-01)
12
+ [Full Changelog](https://github.com/oscar-stack/vagrant-bolt/compare/v0.1.0...v0.1.1)
5
13
 
6
14
  **Merged pull requests:**
7
15
 
data/README.md CHANGED
@@ -194,7 +194,7 @@ VagrantBolt.task(
194
194
  env,
195
195
  machine,
196
196
  run_as: 'root',
197
- bolt_exe: '/usr/local/bin/bolt',
197
+ bolt_exe: '/opt/puppetlabs/bin/bolt',
198
198
  params: { name: "cron", action: "restart" },
199
199
  )
200
200
  ~~~
@@ -216,7 +216,7 @@ The settings available in the triggers and the provisioner are the same.
216
216
 
217
217
  * `bolt_exe`
218
218
  * Description: A string containing the full path to the bolt executable
219
- * Default: `bolt`
219
+ * Default: `/opt/puppetlabs/bin/bolt` if it exists, else the first `bolt` in the PATH
220
220
  * `boltdir`
221
221
  * Description: A string containing the bolt working directory
222
222
  * Default: The vagrant root
@@ -100,7 +100,7 @@ class VagrantBolt::Config::Global < Vagrant.plugin('2', :config)
100
100
  end
101
101
 
102
102
  def finalize!
103
- @bolt_exe = 'bolt' if @bolt_exe == UNSET_VALUE
103
+ @bolt_exe = bolt_exe_path if @bolt_exe == UNSET_VALUE
104
104
  @boltdir = '.' if @boltdir == UNSET_VALUE
105
105
  @connect_timeout = nil if @connect_timeout == UNSET_VALUE
106
106
  @host_key_check = nil if @host_key_check == UNSET_VALUE
@@ -121,6 +121,15 @@ class VagrantBolt::Config::Global < Vagrant.plugin('2', :config)
121
121
  @vars = nil if @vars == UNSET_VALUE
122
122
  end
123
123
 
124
+ # Get the full path to the bolt executable
125
+ # @return [String] The path to the bolt exe
126
+ def bolt_exe_path
127
+ unless Vagrant::Util::Platform.windows?
128
+ return '/opt/puppetlabs/bin/bolt' if File.file?('/opt/puppetlabs/bin/bolt')
129
+ end
130
+ Vagrant::Util::Which.which('bolt') || 'bolt'
131
+ end
132
+
124
133
  def validate(_machine)
125
134
  errors = _detected_errors
126
135
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module VagrantBolt
4
- VERSION = '0.1.1'
4
+ VERSION = '0.1.2'
5
5
  end
@@ -20,8 +20,12 @@ describe VagrantBolt::Config::Global do
20
20
  end
21
21
 
22
22
  context "defaults" do
23
+ before(:each) do
24
+ allow(File).to receive(:file?).with('/opt/puppetlabs/bin/bolt').and_return(true)
25
+ end
26
+
23
27
  expected_values = {
24
- bolt_exe: "bolt",
28
+ bolt_exe: "/opt/puppetlabs/bin/bolt",
25
29
  boltdir: ".",
26
30
  }
27
31
  expected_values.each do |val, expected|
@@ -4,5 +4,5 @@ require_relative '../lib/vagrant-bolt/version'
4
4
  GitHubChangelogGenerator::RakeTask.new :changelog do |config|
5
5
  config.user ='oscar-stack'
6
6
  config.project = 'vagrant-bolt'
7
- config.future_release = VagrantBolt::VERSION
7
+ config.future_release = "v#{VagrantBolt::VERSION}"
8
8
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-bolt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jarret Lavallee
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-07-01 00:00:00.000000000 Z
11
+ date: 2019-10-17 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: " Vagrant provisioning with Puppet Bolt\n"
14
14
  email: