chef 16.17.39 → 16.17.51

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: 3b7f6530e6d244b7ae16b5d56d7de5d455a0caf7658c004ed45e6391092fb4c8
4
- data.tar.gz: bf50c6d69af1bfee408cc09f0c015da63b58202d1dab3791f80cbf529ff6b57a
3
+ metadata.gz: be2ce3e90bf16cdc6e45a5d38437ac5c09ddf28a932941d15e41cefb63799c5e
4
+ data.tar.gz: 62836ee773fddcf98d3754f493140c32ed700f4a8579bfd6635999033993f544
5
5
  SHA512:
6
- metadata.gz: 9b278702cb4b32b11b356c0974795436c490a9eda6c249548b666ee99b83dedb86aab5e8567fb97f19fe6c59bdcdc375c715e3dd37e09f478f51ee1407923806
7
- data.tar.gz: c88559eb2aa8b4d66de72d235e50169b9d4adcbdb0fae63882d8b61908042d85c3d193178e536d2a93cd4de0915cd6cf99a3cd3f98a349acc76c02404effe083
6
+ metadata.gz: 1829789a8720ead98555f765b1d3888e48f34be72490bdd39dc7d98459a1bab97f17818f3163ff52915c03e0e079e391c8751bcabaf6988250fd8ffa29d02e1b
7
+ data.tar.gz: d79cb28151cc22cfb1d924f88c655b058c5fa5a1e89bcb540816b80599415bb8e5346058a6da8cb35487bb32f74fd9f3f7d3a78f51fa2a78931e82ebb1ba700a
@@ -20,6 +20,12 @@
20
20
 
21
21
  require_relative "../resource"
22
22
  require "fileutils" unless defined?(FileUtils)
23
+ begin
24
+ # ffi-libarchive must be eager loaded see: https://github.com/chef/chef/issues/12228
25
+ require "ffi-libarchive" unless defined?(Archive::Reader)
26
+ rescue LoadError
27
+ STDERR.puts "ffi-libarchive could not be loaded, libarchive is probably not installed on system, archive_file will not be available"
28
+ end
23
29
 
24
30
  class Chef
25
31
  class Resource
@@ -88,8 +94,6 @@ class Chef
88
94
  action :extract do
89
95
  description "Extract and archive file."
90
96
 
91
- require_libarchive
92
-
93
97
  unless ::File.exist?(new_resource.path)
94
98
  raise Errno::ENOENT, "No archive found at #{new_resource.path}! Cannot continue."
95
99
  end
@@ -127,10 +131,6 @@ class Chef
127
131
  end
128
132
 
129
133
  action_class do
130
- def require_libarchive
131
- require "ffi-libarchive"
132
- end
133
-
134
134
  def define_resource_requirements
135
135
  if new_resource.mode.is_a?(Integer)
136
136
  Chef.deprecated(:archive_file_integer_file_mode, "The mode property should be passed to archive_file resources as a String and not an Integer to ensure the value is properly interpreted.")
data/lib/chef/version.rb CHANGED
@@ -23,7 +23,7 @@ require_relative "version_string"
23
23
 
24
24
  class Chef
25
25
  CHEF_ROOT = File.expand_path("..", __dir__)
26
- VERSION = Chef::VersionString.new("16.17.39")
26
+ VERSION = Chef::VersionString.new("16.17.51")
27
27
  end
28
28
 
29
29
  #
@@ -17,7 +17,19 @@
17
17
 
18
18
  require "spec_helper"
19
19
 
20
- describe Chef::Resource::ArchiveFile do
20
+ begin
21
+ require "ffi-libarchive"
22
+ rescue LoadError
23
+ module Archive
24
+ class Reader
25
+ def close; end
26
+ def each_entry; end
27
+ def extract(entry, flags = 0, destination: nil); end
28
+ end
29
+ end
30
+ end
31
+
32
+ describe Chef::Resource::ArchiveFile, :not_supported_on_aix do
21
33
  let(:node) { Chef::Node.new }
22
34
  let(:events) { Chef::EventDispatch::Dispatcher.new }
23
35
  let(:run_context) { Chef::RunContext.new(node, {}, events) }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chef
3
3
  version: !ruby/object:Gem::Version
4
- version: 16.17.39
4
+ version: 16.17.51
5
5
  platform: ruby
6
6
  authors:
7
7
  - Adam Jacob
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-01-27 00:00:00.000000000 Z
11
+ date: 2022-02-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: chef-config
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 16.17.39
19
+ version: 16.17.51
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 16.17.39
26
+ version: 16.17.51
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: chef-utils
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 16.17.39
33
+ version: 16.17.51
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 16.17.39
40
+ version: 16.17.51
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: train-core
43
43
  requirement: !ruby/object:Gem::Requirement