kitchen-ansiblepush 0.5.2 → 0.5.3

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: 0ea32f1a6e9d8b8b8d192e5ea4de50405391d936
4
- data.tar.gz: e2f57b3ea5a812781ee0080df0e44ad054ff1ff4
3
+ metadata.gz: cb4b5ceb255051cc628af09ac710a0fadd99931d
4
+ data.tar.gz: d54177928e491e1f6d73e851c6d3baee468b0c5b
5
5
  SHA512:
6
- metadata.gz: cd94e8f964ccb215d564186b2d483e62b60b115b1eaa8ad89955bf7e4f36e822be5536b4e2d9cb78ecd15c07d1da3ab12cab679b0d5459e166ec380be6afdc84
7
- data.tar.gz: d17a8d7c080cbc3fdd9e021456a12e9ddb92ed9838cf4ab2b4459c5bc0b5302e3740e5bd18429694db157906238449cad1934812c1bd1f4b3589f726efcd57dd
6
+ metadata.gz: 7cd93aaac94558292f01820391fd742989db1e901cef5031ed12a6ba1548476861590962e608ab97e782abd1e7ae965c7672aeb3fd57ae7cf935581c23b4c412
7
+ data.tar.gz: 5a4d583388acd1eb84e7a182d811f00628a39ad1c4828c8cb7f5a9b403e6906b9994eb79358dbeb6c6f0b531cd144fd3924058685d828424f0a5b93af581803a
@@ -164,16 +164,16 @@ module Kitchen
164
164
  raise "#{version_check} returned a non zero '#{exit_status}' stdout : #{stdout}, stderr: #{stderr}" unless exit_status.success?
165
165
 
166
166
  omnibus_download_dir = conf[:omnibus_cachier] ? '/tmp/vagrant-cache/omnibus_chef' : '/tmp'
167
- chef_installation(conf[:chef_bootstrap_url], omnibus_download_dir, nil)
167
+ chef_installation(conf[:chef_bootstrap_url], omnibus_download_dir)
168
168
  end
169
169
 
170
- def chef_installation(chef_url, omnibus_download_dir, transport)
170
+ def chef_installation(chef_url, omnibus_download_dir)
171
171
  if chef_url && (chef_url != 'nil') # ignore string nil
172
172
  scripts = []
173
173
  scripts << Util.shell_helpers
174
- scripts << chef_installation_script(chef_url, omnibus_download_dir, transport)
174
+ scripts << chef_installation_script(chef_url, omnibus_download_dir)
175
175
  <<-INSTALL
176
- sh -c "#{scripts.join('\n')}"
176
+ sh -c #{scripts.join("\n")}
177
177
  INSTALL
178
178
  else
179
179
  true_command
@@ -204,11 +204,9 @@ module Kitchen
204
204
  info(" #{task}> #{line.strip}")
205
205
  end
206
206
  end
207
- if conf[:fail_non_idempotent]
208
- raise "idempotency test Failed. Number of non idempotent tasks: #{task}"
209
- else
210
- info('Warning idempotency test [failed]')
211
- end
207
+ raise "idempotency test Failed. Number of non idempotent tasks: #{task}" if conf[:fail_non_idempotent]
208
+ # If we reach this point we should give a warning
209
+ info('Warning idempotency test [failed]')
212
210
  else
213
211
  info('idempotency test [passed]')
214
212
  end
@@ -226,9 +224,7 @@ module Kitchen
226
224
  system(env, command.to_s)
227
225
  exit_code = $CHILD_STATUS.exitstatus
228
226
  debug("ansible-playbook exit code = #{exit_code}")
229
- if exit_code.to_i != 0
230
- raise "#{desc} returned a non zero #{exit_code}. Please see the output above."
231
- end
227
+ raise "#{desc} returned a non zero #{exit_code}. Please see the output above." if exit_code.to_i != 0
232
228
  end
233
229
 
234
230
  def instance_connection_option
@@ -1,14 +1,15 @@
1
1
 
2
2
  def chef_installation_script(chef_url, omnibus_download_dir)
3
3
  <<-INSTALL
4
- if [ ! -d "/opt/chef" ]; then
5
- echo "-----> Installing Chef Omnibus needed by busser and serverspec"
6
- mkdir -p #{omnibus_download_dir}
7
- if [ ! -x #{omnibus_download_dir}/install.sh ]; then
8
- do_download #{chef_url} #{omnibus_download_dir}/install.sh
9
- fi
10
- sudo sh #{omnibus_download_dir}/install.sh -d #{omnibus_download_dir}
11
- echo "-----> End Installing Chef Omnibus"
12
- fi
4
+ if [ ! -d "/opt/chef" ]; then
5
+ echo "-----> Installing Chef Omnibus needed by busser and serverspec"
6
+ echo " You can use https://github.com/neillturner/kitchen-verifier-serverspec to avoid installing chef."
7
+ mkdir -p #{omnibus_download_dir}
8
+ if [ ! -x #{omnibus_download_dir}/install.sh ]; then
9
+ do_download #{chef_url} #{omnibus_download_dir}/install.sh
10
+ fi
11
+ sudo sh #{omnibus_download_dir}/install.sh -d #{omnibus_download_dir}
12
+ echo "-----> End Installing Chef Omnibus"
13
+ fi
13
14
  INSTALL
14
15
  end
@@ -1,5 +1,5 @@
1
1
  module Kitchen
2
2
  module AnsiblePush
3
- VERSION = '0.5.2'.freeze
3
+ VERSION = '0.5.3'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kitchen-ansiblepush
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.2
4
+ version: 0.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Adham Helal
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-12-30 00:00:00.000000000 Z
11
+ date: 2016-12-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: test-kitchen