chef 12.9.41-universal-mingw32 → 12.10.24-universal-mingw32

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.
Files changed (132) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +52 -13
  3. data/README.md +145 -0
  4. data/Rakefile +4 -14
  5. data/VERSION +1 -1
  6. data/acceptance/.gitignore +0 -1
  7. data/acceptance/Gemfile +2 -2
  8. data/acceptance/Gemfile.lock +235 -0
  9. data/acceptance/fips/.kitchen.yml +5 -1
  10. data/acceptance/fips/test/integration/{fips → fips-integration}/serverspec/Gemfile +0 -0
  11. data/acceptance/fips/test/integration/fips-integration/serverspec/fips-integration_spec.rb +51 -0
  12. data/acceptance/fips/test/integration/fips-unit-functional/serverspec/Gemfile +3 -0
  13. data/acceptance/fips/test/integration/fips-unit-functional/serverspec/fips-unit-functional_spec.rb +56 -0
  14. data/{chef-windows.gemspec → chef-universal-mingw32.gemspec} +0 -0
  15. data/chef.gemspec +0 -6
  16. data/{lib → lib-backcompat}/chef/chef_fs/file_system/already_exists_error.rb +0 -0
  17. data/{lib → lib-backcompat}/chef/chef_fs/file_system/cookbook_frozen_error.rb +0 -0
  18. data/{lib → lib-backcompat}/chef/chef_fs/file_system/default_environment_cannot_be_modified_error.rb +0 -0
  19. data/{lib → lib-backcompat}/chef/chef_fs/file_system/file_system_error.rb +0 -0
  20. data/{lib → lib-backcompat}/chef/chef_fs/file_system/must_delete_recursively_error.rb +0 -0
  21. data/{lib → lib-backcompat}/chef/chef_fs/file_system/not_found_error.rb +0 -0
  22. data/{lib → lib-backcompat}/chef/chef_fs/file_system/operation_failed_error.rb +0 -0
  23. data/{lib → lib-backcompat}/chef/chef_fs/file_system/operation_not_allowed_error.rb +0 -0
  24. data/lib-backcompat/chef/chef_fs/file_system/repository/chef_repository_file_system_acls_dir.rb +5 -0
  25. data/lib-backcompat/chef/chef_fs/file_system/repository/chef_repository_file_system_client_keys_dir.rb +5 -0
  26. data/lib-backcompat/chef/chef_fs/file_system/repository/chef_repository_file_system_entry.rb +6 -0
  27. data/lib-backcompat/chef/chef_fs/file_system/repository/chef_repository_file_system_policies_dir.rb +5 -0
  28. data/{lib → lib-backcompat}/chef/chef_fs/file_system/repository/file_system_root_dir.rb +1 -0
  29. data/lib/chef/chef_fs/file_system/repository/acl.rb +38 -0
  30. data/lib/chef/chef_fs/file_system/repository/{chef_repository_file_system_acls_dir.rb → acls_dir.rb} +14 -5
  31. data/lib/chef/chef_fs/file_system/repository/acls_sub_dir.rb +42 -0
  32. data/lib/chef/chef_fs/file_system/repository/base_file.rb +120 -0
  33. data/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_cookbook_entry.rb +1 -1
  34. data/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_root_dir.rb +36 -32
  35. data/lib/chef/chef_fs/file_system/repository/client.rb +38 -0
  36. data/lib/chef/chef_fs/file_system/repository/client_key.rb +38 -0
  37. data/lib/chef/chef_fs/file_system/repository/{chef_repository_file_system_client_keys_dir.rb → client_keys_dir.rb} +9 -5
  38. data/lib/chef/chef_fs/file_system/repository/client_keys_sub_dir.rb +42 -0
  39. data/lib/chef/chef_fs/file_system/repository/clients_dir.rb +40 -0
  40. data/lib/chef/chef_fs/file_system/repository/container.rb +38 -0
  41. data/lib/chef/chef_fs/file_system/repository/containers_dir.rb +41 -0
  42. data/lib/chef/chef_fs/file_system/repository/cookbooks_dir.rb +0 -1
  43. data/lib/chef/chef_fs/file_system/repository/data_bag_item.rb +3 -79
  44. data/lib/chef/chef_fs/file_system/repository/directory.rb +15 -2
  45. data/lib/chef/chef_fs/file_system/repository/environment.rb +38 -0
  46. data/lib/chef/chef_fs/file_system/repository/environments_dir.rb +41 -0
  47. data/lib/chef/chef_fs/file_system/repository/file_system_entry.rb +66 -30
  48. data/lib/chef/chef_fs/file_system/repository/group.rb +38 -0
  49. data/lib/chef/chef_fs/file_system/repository/groups_dir.rb +41 -0
  50. data/lib/chef/chef_fs/file_system/repository/node.rb +38 -0
  51. data/lib/chef/chef_fs/file_system/repository/nodes_dir.rb +41 -0
  52. data/lib/chef/chef_fs/file_system/repository/{chef_repository_file_system_policies_dir.rb → policies_dir.rb} +9 -5
  53. data/lib/chef/chef_fs/file_system/repository/policy.rb +38 -0
  54. data/lib/chef/chef_fs/file_system/repository/policy_group.rb +38 -0
  55. data/lib/chef/chef_fs/file_system/repository/policy_groups_dir.rb +41 -0
  56. data/lib/chef/chef_fs/file_system/repository/role.rb +38 -0
  57. data/lib/chef/chef_fs/file_system/repository/roles_dir.rb +41 -0
  58. data/lib/chef/chef_fs/file_system/repository/user.rb +38 -0
  59. data/lib/chef/chef_fs/file_system/repository/users_dir.rb +41 -0
  60. data/lib/chef/dsl/declare_resource.rb +182 -7
  61. data/lib/chef/http/json_input.rb +2 -2
  62. data/lib/chef/knife.rb +1 -1
  63. data/lib/chef/mixin/shell_out.rb +10 -21
  64. data/lib/chef/property.rb +9 -2
  65. data/lib/chef/provider.rb +8 -7
  66. data/lib/chef/provider/apt_repository.rb +8 -6
  67. data/lib/chef/provider/directory.rb +15 -1
  68. data/lib/chef/provider/env/windows.rb +1 -1
  69. data/lib/chef/provider/mdadm.rb +1 -0
  70. data/lib/chef/provider/package/easy_install.rb +2 -0
  71. data/lib/chef/provider/package/rubygems.rb +4 -1
  72. data/lib/chef/provider/package/windows.rb +1 -1
  73. data/lib/chef/recipe.rb +1 -2
  74. data/lib/chef/resource/apt_repository.rb +6 -6
  75. data/lib/chef/resource/mdadm.rb +9 -0
  76. data/lib/chef/resource_collection.rb +5 -0
  77. data/lib/chef/resource_collection/resource_list.rb +10 -0
  78. data/lib/chef/resource_collection/resource_set.rb +14 -11
  79. data/lib/chef/version.rb +1 -1
  80. data/spec/functional/resource/git_spec.rb +1 -3
  81. data/spec/functional/resource/group_spec.rb +5 -5
  82. data/spec/functional/tiny_server_spec.rb +1 -1
  83. data/spec/functional/util/powershell/cmdlet_spec.rb +1 -1
  84. data/spec/functional/win32/registry_spec.rb +3 -3
  85. data/spec/integration/solo/solo_spec.rb +2 -2
  86. data/spec/support/shared/functional/securable_resource.rb +1 -1
  87. data/spec/support/shared/unit/provider/file.rb +3 -3
  88. data/spec/support/shared/unit/windows_script_resource.rb +1 -1
  89. data/spec/unit/application/apply_spec.rb +1 -0
  90. data/spec/unit/chef_fs/file_system/repository/base_file_spec.rb +128 -0
  91. data/spec/unit/chef_fs/file_system/repository/directory_spec.rb +174 -0
  92. data/spec/unit/cookbook/metadata_spec.rb +1 -1
  93. data/spec/unit/dsl/declare_resource_spec.rb +335 -0
  94. data/spec/unit/knife/bootstrap_spec.rb +2 -2
  95. data/spec/unit/mixin/shell_out_spec.rb +4 -0
  96. data/spec/unit/node/attribute_spec.rb +1 -1
  97. data/spec/unit/node/immutable_collections_spec.rb +2 -2
  98. data/spec/unit/node_map_spec.rb +1 -1
  99. data/spec/unit/property/validation_spec.rb +23 -7
  100. data/spec/unit/provider/apt_repository_spec.rb +5 -0
  101. data/spec/unit/provider/apt_update_spec.rb +1 -0
  102. data/spec/unit/provider/directory_spec.rb +0 -7
  103. data/spec/unit/provider/file/content_spec.rb +1 -1
  104. data/spec/unit/provider/mdadm_spec.rb +9 -0
  105. data/spec/unit/provider/package/easy_install_spec.rb +6 -0
  106. data/spec/unit/provider/package/rubygems_spec.rb +8 -4
  107. data/spec/unit/provider/package/yum_spec.rb +1 -1
  108. data/spec/unit/provider/powershell_script_spec.rb +1 -1
  109. data/spec/unit/provider/user/dscl_spec.rb +6 -6
  110. data/spec/unit/recipe_spec.rb +1 -0
  111. data/spec/unit/resource/apt_repository_spec.rb +4 -0
  112. data/spec/unit/resource/file/verification_spec.rb +1 -1
  113. data/spec/unit/resource/file_spec.rb +2 -2
  114. data/spec/unit/resource/mdadm_spec.rb +7 -2
  115. data/spec/unit/resource_collection_spec.rb +30 -0
  116. data/spec/unit/resource_spec.rb +1 -1
  117. data/tasks/bin/bundle-platform +15 -0
  118. data/tasks/bin/bundle-platform.bat +2 -0
  119. data/tasks/bin/create-override-gemfile +110 -0
  120. data/tasks/bin/run_chef_tests +17 -0
  121. data/tasks/bin/run_external_test +47 -0
  122. data/tasks/bundle.rb +97 -0
  123. data/tasks/bundle_util.rb +94 -0
  124. data/tasks/changelog.rb +12 -0
  125. data/tasks/dependencies.rb +147 -0
  126. data/tasks/gemfile_util.rb +390 -0
  127. data/tasks/maintainers.rb +2 -1
  128. data/tasks/rspec.rb +2 -1
  129. metadata +61 -83
  130. data/acceptance/fips/test/integration/fips/serverspec/fips_spec.rb +0 -39
  131. data/lib/chef/chef_fs/file_system/repository/chef_repository_file_system_entry.rb +0 -83
  132. data/tasks/external_tests.rb +0 -64
@@ -1,4 +1,8 @@
1
1
  suites:
2
- - name: fips
2
+ - name: fips-unit-functional
3
+ includes: [centos-6, windows-2012r2]
4
+ run_list:
5
+
6
+ - name: fips-integration
3
7
  includes: [centos-6, windows-2012r2]
4
8
  run_list:
@@ -0,0 +1,51 @@
1
+ require "mixlib/shellout"
2
+ require "bundler"
3
+
4
+ describe "Chef Fips Integration Specs" do
5
+ def windows?
6
+ if RUBY_PLATFORM =~ /mswin|mingw|windows/
7
+ true
8
+ else
9
+ false
10
+ end
11
+ end
12
+
13
+ let(:omnibus_root) do
14
+ if windows?
15
+ "c:/opscode/chef"
16
+ else
17
+ "/opt/chef"
18
+ end
19
+ end
20
+
21
+ let(:env) do
22
+ {
23
+ "PATH" => [ "#{omnibus_root}/embedded/bin", ENV["PATH"] ].join(File::PATH_SEPARATOR),
24
+ "BUNDLE_GEMFILE" => "#{omnibus_root}/Gemfile",
25
+ "GEM_PATH" => nil, "GEM_CACHE" => nil, "GEM_HOME" => nil,
26
+ "BUNDLE_IGNORE_CONFIG" => "true",
27
+ "BUNDLE_FROZEN" => "1",
28
+ "CHEF_FIPS" => "1"
29
+ }
30
+ end
31
+
32
+ let(:chef_dir) do
33
+ cmd = Mixlib::ShellOut.new("bundle show chef", env: env).run_command
34
+ cmd.error!
35
+ cmd.stdout.chomp
36
+ end
37
+
38
+ def run_rspec_test(test)
39
+ Bundler.with_clean_env do
40
+ cmd = Mixlib::ShellOut.new(
41
+ "bundle exec rspec -f documentation -t ~requires_git #{test}",
42
+ env: env, cwd: chef_dir, timeout: 3600
43
+ )
44
+ cmd.run_command.error!
45
+ end
46
+ end
47
+
48
+ it "passes the integration specs" do
49
+ run_rspec_test("spec/integration")
50
+ end
51
+ end
@@ -0,0 +1,3 @@
1
+ source "https://rubygems.org"
2
+
3
+ gem "mixlib-shellout"
@@ -0,0 +1,56 @@
1
+ require "mixlib/shellout"
2
+ require "bundler"
3
+
4
+ describe "Chef Fips Unit/Functional Specs" do
5
+ def windows?
6
+ if RUBY_PLATFORM =~ /mswin|mingw|windows/
7
+ true
8
+ else
9
+ false
10
+ end
11
+ end
12
+
13
+ let(:omnibus_root) do
14
+ if windows?
15
+ "c:/opscode/chef"
16
+ else
17
+ "/opt/chef"
18
+ end
19
+ end
20
+
21
+ let(:env) do
22
+ {
23
+ "PATH" => [ "#{omnibus_root}/embedded/bin", ENV["PATH"] ].join(File::PATH_SEPARATOR),
24
+ "BUNDLE_GEMFILE" => "#{omnibus_root}/Gemfile",
25
+ "GEM_PATH" => nil, "GEM_CACHE" => nil, "GEM_HOME" => nil,
26
+ "BUNDLE_IGNORE_CONFIG" => "true",
27
+ "BUNDLE_FROZEN" => "1",
28
+ "CHEF_FIPS" => "1"
29
+ }
30
+ end
31
+
32
+ let(:chef_dir) do
33
+ cmd = Mixlib::ShellOut.new("bundle show chef", env: env).run_command
34
+ cmd.error!
35
+ cmd.stdout.chomp
36
+ end
37
+
38
+ def run_rspec_test(test)
39
+ Bundler.with_clean_env do
40
+ cmd = Mixlib::ShellOut.new(
41
+ "bundle exec rspec -f documentation -t ~requires_git #{test}",
42
+ env: env, cwd: chef_dir, timeout: 3600
43
+ )
44
+ cmd.run_command.error!
45
+ end
46
+ end
47
+
48
+ it "passes the unit specs" do
49
+ run_rspec_test("spec/unit")
50
+ end
51
+
52
+ it "passes the functional specs" do
53
+ run_rspec_test("spec/functional")
54
+ end
55
+
56
+ end
@@ -50,12 +50,6 @@ Gem::Specification.new do |s|
50
50
  # very deliberately avoiding putting a ceiling on this to avoid depsolver conflicts.
51
51
  s.add_dependency "bundler", ">= 1.10"
52
52
 
53
- s.add_development_dependency "rack"
54
- s.add_development_dependency "cheffish", ">= 1.1", "< 3.0"
55
- s.add_development_dependency "github_changelog_generator", "1.11.3"
56
-
57
- s.add_development_dependency "rake", "~> 10.1"
58
-
59
53
  s.bindir = "bin"
60
54
  s.executables = %w{ chef-client chef-solo knife chef-shell chef-apply }
61
55
 
@@ -0,0 +1,5 @@
1
+ require "chef/chef_fs/file_system/repository/acls_dir"
2
+
3
+ module Chef::ChefFS::FileSystem::Repository
4
+ ChefRepositoryFileSystemAclsDir = AclsDir
5
+ end
@@ -0,0 +1,5 @@
1
+ require "chef/chef_fs/file_system/repository/client_keys_dir"
2
+
3
+ module Chef::ChefFS::FileSystem::Repository
4
+ ChefRepositoryFileSystemClientKeysDir = ClientKeysDir
5
+ end
@@ -0,0 +1,6 @@
1
+ require "chef/chef_fs/file_system/repository/file_system_entry"
2
+
3
+ module Chef::ChefFS::FileSystem::Repository
4
+ Chef.log_deprecation "Chef::ChefFS::FileSystem::Repository::ChefRepositoryFileSystemEntry is deprecated. Please use FileSystemEntry directly"
5
+ ChefRepositoryFileSystemEntry = FileSystemEntry
6
+ end
@@ -0,0 +1,5 @@
1
+ require "chef/chef_fs/file_system/repository/policies_dir"
2
+
3
+ module Chef::ChefFS::FileSystem::Repository
4
+ ChefRepositoryFileSystemPoliciesDir = PoliciesDir
5
+ end
@@ -24,6 +24,7 @@ class Chef
24
24
  module Repository
25
25
  class FileSystemRootDir < FileSystemEntry
26
26
  def initialize(file_path)
27
+ Chef.log_deprecation "Chef::ChefFS::FileSystem::Repository::FileSystemRootDir is deprecated."
27
28
  super("", nil, file_path)
28
29
  end
29
30
  end
@@ -0,0 +1,38 @@
1
+ #
2
+ # Author:: Thom May (<thom@chef.io>)
3
+ # Copyright:: Copyright 2013-2016, Chef Software Inc.
4
+ # License:: Apache License, Version 2.0
5
+ #
6
+ # Licensed under the Apache License, Version 2.0 (the "License");
7
+ # you may not use this file except in compliance with the License.
8
+ # You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing, software
13
+ # distributed under the License is distributed on an "AS IS" BASIS,
14
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ # See the License for the specific language governing permissions and
16
+ # limitations under the License.
17
+ #
18
+
19
+ require "chef/chef_fs/data_handler/acl_data_handler"
20
+ require "chef/chef_fs/file_system/repository/base_file"
21
+
22
+ class Chef
23
+ module ChefFS
24
+ module FileSystem
25
+ module Repository
26
+
27
+ class Acl < BaseFile
28
+
29
+ def initialize(name, parent)
30
+ @data_handler = Chef::ChefFS::DataHandler::AclDataHandler.new
31
+ super
32
+ end
33
+
34
+ end
35
+ end
36
+ end
37
+ end
38
+ end
@@ -16,7 +16,9 @@
16
16
  # limitations under the License.
17
17
  #
18
18
 
19
- require "chef/chef_fs/file_system/repository/chef_repository_file_system_entry"
19
+ require "chef/chef_fs/file_system/repository/acl"
20
+ require "chef/chef_fs/file_system/repository/directory"
21
+ require "chef/chef_fs/file_system/repository/acls_sub_dir"
20
22
  require "chef/chef_fs/file_system/chef_server/acls_dir"
21
23
  require "chef/chef_fs/data_handler/acl_data_handler"
22
24
 
@@ -24,14 +26,21 @@ class Chef
24
26
  module ChefFS
25
27
  module FileSystem
26
28
  module Repository
27
- class ChefRepositoryFileSystemAclsDir < ChefRepositoryFileSystemEntry
28
- def initialize(name, parent, path = nil)
29
- super(name, parent, path, Chef::ChefFS::DataHandler::AclDataHandler.new)
30
- end
29
+ class AclsDir < Repository::Directory
31
30
 
32
31
  def can_have_child?(name, is_dir)
33
32
  is_dir ? Chef::ChefFS::FileSystem::ChefServer::AclsDir::ENTITY_TYPES.include?(name) : name == "organization.json"
34
33
  end
34
+
35
+ protected
36
+
37
+ def make_child_entry(child_name)
38
+ if child_name == "organization.json"
39
+ Acl.new(child_name, self)
40
+ else
41
+ AclsSubDir.new(child_name, self)
42
+ end
43
+ end
35
44
  end
36
45
  end
37
46
  end
@@ -0,0 +1,42 @@
1
+ #
2
+ # Author:: Jordan Running (<jr@chef.io>)
3
+ # Copyright:: Copyright 2013-2016, Chef Software Inc.
4
+ # License:: Apache License, Version 2.0
5
+ #
6
+ # Licensed under the Apache License, Version 2.0 (the "License");
7
+ # you may not use this file except in compliance with the License.
8
+ # You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing, software
13
+ # distributed under the License is distributed on an "AS IS" BASIS,
14
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ # See the License for the specific language governing permissions and
16
+ # limitations under the License.
17
+ #
18
+
19
+ require "chef/chef_fs/file_system/repository/acl"
20
+ require "chef/chef_fs/data_handler/acl_data_handler"
21
+ require "chef/chef_fs/file_system/repository/directory"
22
+
23
+ class Chef
24
+ module ChefFS
25
+ module FileSystem
26
+ module Repository
27
+ class AclsSubDir < Repository::Directory
28
+
29
+ def can_have_child?(name, is_dir)
30
+ !is_dir && File.extname(name) == ".json"
31
+ end
32
+
33
+ protected
34
+
35
+ def make_child_entry(child_name)
36
+ Acl.new(child_name, self)
37
+ end
38
+ end
39
+ end
40
+ end
41
+ end
42
+ end
@@ -0,0 +1,120 @@
1
+ #
2
+ # Author:: Thom May (<thom@chef.io>)
3
+ # Copyright:: Copyright 2013-2016, Chef Software Inc.
4
+ # License:: Apache License, Version 2.0
5
+ #
6
+ # Licensed under the Apache License, Version 2.0 (the "License");
7
+ # you may not use this file except in compliance with the License.
8
+ # You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing, software
13
+ # distributed under the License is distributed on an "AS IS" BASIS,
14
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ # See the License for the specific language governing permissions and
16
+ # limitations under the License.
17
+ #
18
+
19
+ class Chef
20
+ module ChefFS
21
+ module FileSystem
22
+ module Repository
23
+
24
+ class BaseFile
25
+
26
+ attr_reader :name
27
+ attr_reader :parent
28
+ attr_reader :path
29
+ attr_reader :file_path
30
+ attr_reader :data_handler
31
+
32
+ def initialize(name, parent)
33
+ @parent = parent
34
+ @name = name
35
+ @path = Chef::ChefFS::PathUtils.join(parent.path, name)
36
+ @file_path = "#{parent.file_path}/#{name}"
37
+ end
38
+
39
+ def dir?
40
+ false
41
+ end
42
+
43
+ def is_json_file?
44
+ File.extname(name) == ".json"
45
+ end
46
+
47
+ def name_valid?
48
+ !name.start_with?(".") && is_json_file?
49
+ end
50
+
51
+ def fs_entry_valid?
52
+ name_valid? && exists?
53
+ end
54
+
55
+ def create(file_contents)
56
+ if exists?
57
+ raise Chef::ChefFS::FileSystem::AlreadyExistsError.new(:create_child, self)
58
+ else
59
+ write(file_contents)
60
+ end
61
+ end
62
+
63
+ def can_have_child?(name, is_dir)
64
+ false
65
+ end
66
+
67
+ attr_writer :write_pretty_json
68
+ def write_pretty_json
69
+ @write_pretty_json.nil? ? root.write_pretty_json : @write_pretty_json
70
+ end
71
+
72
+ def path_for_printing
73
+ file_path
74
+ end
75
+
76
+ def delete(_)
77
+ File.delete(file_path)
78
+ rescue Errno::ENOENT
79
+ raise Chef::ChefFS::FileSystem::NotFoundError.new(self, $!)
80
+ end
81
+
82
+ def exists?
83
+ File.file?(file_path)
84
+ end
85
+
86
+ def minimize(content, entry)
87
+ object = Chef::JSONCompat.parse(content)
88
+ object = data_handler.normalize(object, entry)
89
+ object = data_handler.minimize(object, entry)
90
+ Chef::JSONCompat.to_json_pretty(object)
91
+ end
92
+
93
+ def read
94
+ File.open(file_path, "rb") { |f| f.read }
95
+ rescue Errno::ENOENT
96
+ raise Chef::ChefFS::FileSystem::NotFoundError.new(self, $!)
97
+ end
98
+
99
+ def write(content)
100
+ if content && write_pretty_json && is_json_file?
101
+ content = minimize(content, self)
102
+ end
103
+ File.open(file_path, "wb") do |file|
104
+ file.write(content)
105
+ end
106
+ end
107
+
108
+ def root
109
+ parent.root
110
+ end
111
+
112
+ def compare_to(other)
113
+ nil
114
+ end
115
+
116
+ end
117
+ end
118
+ end
119
+ end
120
+ end
@@ -16,7 +16,7 @@
16
16
  # limitations under the License.
17
17
  #
18
18
 
19
- require "chef/chef_fs/file_system/repository/chef_repository_file_system_entry"
19
+ require "chef/chef_fs/file_system/repository/file_system_entry"
20
20
  require "chef/chef_fs/file_system/repository/cookbooks_dir"
21
21
  require "chef/chef_fs/file_system/exceptions"
22
22