summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2020-11-13 11:47:09 -0800
committerGitHub <noreply@github.com>2020-11-13 11:47:09 -0800
commit654d87c2e90fb5a8f751067ec1923ef2f9e92114 (patch)
tree38f268d383d4bf94128fc4bb8ecc6be69e71147c
parent3020773f943536e59a98a2fa72823288825ef9c6 (diff)
parent74ef923ee6a619c1298718a526ded55098012c70 (diff)
downloadchef-654d87c2e90fb5a8f751067ec1923ef2f9e92114.tar.gz
Merge pull request #10644 from chef/resolver
Signed-off-by: Tim Smith <tsmith@chef.io>
-rw-r--r--distro/ruby_bin_folder/AMD64/Chef.PowerShell.Wrapper.dllbin169984 -> 169984 bytes
-rw-r--r--distro/ruby_bin_folder/AMD64/Chef.PowerShell.dllbin6144 -> 6144 bytes
-rw-r--r--distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dllbin97792 -> 97792 bytes
-rw-r--r--distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dllbin5632 -> 5632 bytes
-rw-r--r--distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdbbin1404 -> 1404 bytes
-rw-r--r--distro/ruby_bin_folder/x86/Chef.PowerShell.dllbin6656 -> 6656 bytes
-rw-r--r--distro/ruby_bin_folder/x86/Chef.Powershell.Wrapper.dllbin144896 -> 145920 bytes
-rw-r--r--distro/ruby_bin_folder/x86/concrt140.dllbin244608 -> 244088 bytes
-rw-r--r--distro/ruby_bin_folder/x86/msvcp140.dllbin448384 -> 450952 bytes
-rw-r--r--distro/ruby_bin_folder/x86/msvcp140_1.dllbin21384 -> 21376 bytes
-rw-r--r--distro/ruby_bin_folder/x86/msvcp140_2.dllbin166792 -> 166776 bytes
-rw-r--r--distro/ruby_bin_folder/x86/msvcp140_atomic_wait.dllbin0 -> 39296 bytes
-rw-r--r--distro/ruby_bin_folder/x86/msvcp140_codecvt_ids.dllbin18824 -> 18808 bytes
-rw-r--r--distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dllbin82944 -> 83456 bytes
-rw-r--r--distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dllbin6144 -> 6144 bytes
-rw-r--r--distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdbbin1408 -> 1408 bytes
-rw-r--r--distro/ruby_bin_folder/x86/vccorlib140.dllbin267648 -> 267656 bytes
-rw-r--r--distro/ruby_bin_folder/x86/vcruntime140.dllbin76168 -> 76152 bytes
-rw-r--r--lib/chef/powershell.rb10
19 files changed, 1 insertions, 9 deletions
diff --git a/distro/ruby_bin_folder/AMD64/Chef.PowerShell.Wrapper.dll b/distro/ruby_bin_folder/AMD64/Chef.PowerShell.Wrapper.dll
index 0a5d80632c..4b1a0dd692 100644
--- a/distro/ruby_bin_folder/AMD64/Chef.PowerShell.Wrapper.dll
+++ b/distro/ruby_bin_folder/AMD64/Chef.PowerShell.Wrapper.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/AMD64/Chef.PowerShell.dll b/distro/ruby_bin_folder/AMD64/Chef.PowerShell.dll
index 1143fe1175..19f5e0f1ed 100644
--- a/distro/ruby_bin_folder/AMD64/Chef.PowerShell.dll
+++ b/distro/ruby_bin_folder/AMD64/Chef.PowerShell.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dll b/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dll
index 52beb787b3..e8f475c3dc 100644
--- a/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dll
+++ b/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dll b/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dll
index 0c07278003..573150ab44 100644
--- a/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dll
+++ b/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdb b/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdb
index 2479087bd2..244a59acc4 100644
--- a/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdb
+++ b/distro/ruby_bin_folder/AMD64/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdb
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/Chef.PowerShell.dll b/distro/ruby_bin_folder/x86/Chef.PowerShell.dll
index 70dc1a0318..6e405d878f 100644
--- a/distro/ruby_bin_folder/x86/Chef.PowerShell.dll
+++ b/distro/ruby_bin_folder/x86/Chef.PowerShell.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/Chef.Powershell.Wrapper.dll b/distro/ruby_bin_folder/x86/Chef.Powershell.Wrapper.dll
index 4f243e70bc..f148f6e6a5 100644
--- a/distro/ruby_bin_folder/x86/Chef.Powershell.Wrapper.dll
+++ b/distro/ruby_bin_folder/x86/Chef.Powershell.Wrapper.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/concrt140.dll b/distro/ruby_bin_folder/x86/concrt140.dll
index 5649eefca4..1d75093197 100644
--- a/distro/ruby_bin_folder/x86/concrt140.dll
+++ b/distro/ruby_bin_folder/x86/concrt140.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/msvcp140.dll b/distro/ruby_bin_folder/x86/msvcp140.dll
index 053520472c..76529d554a 100644
--- a/distro/ruby_bin_folder/x86/msvcp140.dll
+++ b/distro/ruby_bin_folder/x86/msvcp140.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/msvcp140_1.dll b/distro/ruby_bin_folder/x86/msvcp140_1.dll
index 3e027a48f2..4dfe3ee783 100644
--- a/distro/ruby_bin_folder/x86/msvcp140_1.dll
+++ b/distro/ruby_bin_folder/x86/msvcp140_1.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/msvcp140_2.dll b/distro/ruby_bin_folder/x86/msvcp140_2.dll
index 6baf5a6019..8f251b32cc 100644
--- a/distro/ruby_bin_folder/x86/msvcp140_2.dll
+++ b/distro/ruby_bin_folder/x86/msvcp140_2.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/msvcp140_atomic_wait.dll b/distro/ruby_bin_folder/x86/msvcp140_atomic_wait.dll
new file mode 100644
index 0000000000..4c758375f7
--- /dev/null
+++ b/distro/ruby_bin_folder/x86/msvcp140_atomic_wait.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/msvcp140_codecvt_ids.dll b/distro/ruby_bin_folder/x86/msvcp140_codecvt_ids.dll
index 128405f0f8..efa73e134b 100644
--- a/distro/ruby_bin_folder/x86/msvcp140_codecvt_ids.dll
+++ b/distro/ruby_bin_folder/x86/msvcp140_codecvt_ids.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dll b/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dll
index 510e99770d..0d282b5d39 100644
--- a/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dll
+++ b/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.PowerShell.Wrapper.Core.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dll b/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dll
index c97035476a..1b53a46076 100644
--- a/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dll
+++ b/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdb b/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdb
index fe5122be63..269329e5f2 100644
--- a/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdb
+++ b/distro/ruby_bin_folder/x86/shared/Microsoft.NETCore.App/3.1.8/Chef.Powershell.Core.pdb
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/vccorlib140.dll b/distro/ruby_bin_folder/x86/vccorlib140.dll
index f41c246b46..f9933d56ac 100644
--- a/distro/ruby_bin_folder/x86/vccorlib140.dll
+++ b/distro/ruby_bin_folder/x86/vccorlib140.dll
Binary files differ
diff --git a/distro/ruby_bin_folder/x86/vcruntime140.dll b/distro/ruby_bin_folder/x86/vcruntime140.dll
index 9958562d2d..dc526fc062 100644
--- a/distro/ruby_bin_folder/x86/vcruntime140.dll
+++ b/distro/ruby_bin_folder/x86/vcruntime140.dll
Binary files differ
diff --git a/lib/chef/powershell.rb b/lib/chef/powershell.rb
index 4800708dfc..905b92ebfb 100644
--- a/lib/chef/powershell.rb
+++ b/lib/chef/powershell.rb
@@ -63,15 +63,7 @@ class Chef
def exec(script)
FFI.ffi_lib @dll
FFI.attach_function :execute_powershell, :ExecuteScript, [:string], :pointer
- # This is a temporary fix for running in a Habitat environment
- # In habitat we set CHEF_POWERSHELL_BIN so that .Net resolves our
- # managed shim assembly from the correct location.
- # It seems that that is preventing .Net from successfully loading GAC assemblies
- # and can break all sorts of edge (and not so edge) scenarios. Once we are actually
- # inside the powershell run space, we know our shim was loaded and can unset
- # CHEF_POWERSHELL_BIN which will bypass our custom resolver logic. The real fix is
- # to fix our resolver. Oh and OH MY GOD this was a pain to track down.
- execution = FFI.execute_powershell("$ENV:CHEF_POWERSHELL_BIN=$NULL;#{script}").read_utf16string
+ execution = FFI.execute_powershell(script).read_utf16string
hashed_outcome = Chef::JSONCompat.parse(execution)
@result = Chef::JSONCompat.parse(hashed_outcome["result"])
@errors = hashed_outcome["errors"]