diff --git a/lib/puppet/provider/base_dsc_lite/powershell.rb b/lib/puppet/provider/base_dsc_lite/powershell.rb index d1f72044..c0122c33 100644 --- a/lib/puppet/provider/base_dsc_lite/powershell.rb +++ b/lib/puppet/provider/base_dsc_lite/powershell.rb @@ -6,8 +6,8 @@ Puppet::Type.type(:base_dsc_lite).provide(:powershell) do confine feature: :pwshlib - confine operatingsystem: :windows - defaultfor operatingsystem: :windows + confine 'os.name' => :windows + defaultfor 'os.name' => :windows commands powershell: (if File.exist?("#{ENV.fetch('SYSTEMROOT', nil)}\\sysnative\\WindowsPowershell\\v1.0\\powershell.exe") "#{ENV.fetch('SYSTEMROOT', nil)}\\sysnative\\WindowsPowershell\\v1.0\\powershell.exe" diff --git a/lib/puppet/type/dsc.rb b/lib/puppet/type/dsc.rb index e48bb33d..5030fad2 100644 --- a/lib/puppet/type/dsc.rb +++ b/lib/puppet/type/dsc.rb @@ -124,7 +124,7 @@ def change_to_s(currentvalue, newvalue) Provider for dsc type DOC confine feature: :dsc_lite - defaultfor operatingsystem: :windows + defaultfor 'os.name' => :windows mk_resource_methods end diff --git a/spec/fixtures/dsc_puppetfakeresource/dsc_puppetfakeresource.rb b/spec/fixtures/dsc_puppetfakeresource/dsc_puppetfakeresource.rb index c62a253b..72011357 100755 --- a/spec/fixtures/dsc_puppetfakeresource/dsc_puppetfakeresource.rb +++ b/spec/fixtures/dsc_puppetfakeresource/dsc_puppetfakeresource.rb @@ -127,7 +127,7 @@ def builddepends Puppet::Type.type(:dsc_puppetfakeresource).provide :powershell, :parent => Puppet::Type.type(:base_dsc_lite).provider(:powershell) do confine :feature => :dsc_lite - defaultfor :operatingsystem => :windows + defaultfor 'os.name' => :windows mk_resource_methods end