diff options
author | Serdar Sutay <serdar@opscode.com> | 2014-10-28 11:59:54 -0700 |
---|---|---|
committer | Serdar Sutay <serdar@opscode.com> | 2014-10-28 18:37:31 -0700 |
commit | 8cefc070070c23dc1824beb2bd8551dc88014635 (patch) | |
tree | 69d81bf64fc19a3b44676a3607c055d904ba83af /lib/chef | |
parent | 40ae6e04dceb5ee1020fe42390e2dae627cc02b4 (diff) | |
download | chef-8cefc070070c23dc1824beb2bd8551dc88014635.tar.gz |
Make sure windows_service and windows_package resources are found with the new dynamic provider resolver.
Diffstat (limited to 'lib/chef')
-rw-r--r-- | lib/chef/provider/package/windows.rb | 7 | ||||
-rw-r--r-- | lib/chef/provider/service/windows.rb | 1 | ||||
-rw-r--r-- | lib/chef/resource/windows_package.rb | 3 | ||||
-rw-r--r-- | lib/chef/resource/windows_service.rb | 3 |
4 files changed, 10 insertions, 4 deletions
diff --git a/lib/chef/provider/package/windows.rb b/lib/chef/provider/package/windows.rb index 25be5b822c..143d82f111 100644 --- a/lib/chef/provider/package/windows.rb +++ b/lib/chef/provider/package/windows.rb @@ -25,8 +25,11 @@ class Chef class Package class Windows < Chef::Provider::Package - # Depending on the installer, we may need to examine installer_type or - # source attributes, or search for text strings in the installer file + provides :package, os: "windows" + provides :windows_package, os: "windows" + + # Depending on the installer, we may need to examine installer_type or + # source attributes, or search for text strings in the installer file # binary to determine the installer type for the user. Since the file # must be on disk to do so, we have to make this choice in the provider. require 'chef/provider/package/windows/msi.rb' diff --git a/lib/chef/provider/service/windows.rb b/lib/chef/provider/service/windows.rb index 4b1d2079ec..d4c272354e 100644 --- a/lib/chef/provider/service/windows.rb +++ b/lib/chef/provider/service/windows.rb @@ -26,6 +26,7 @@ end class Chef::Provider::Service::Windows < Chef::Provider::Service provides :service, os: "windows" + provides :windows_service, os: "windows" include Chef::Mixin::ShellOut diff --git a/lib/chef/resource/windows_package.rb b/lib/chef/resource/windows_package.rb index 9bf3443423..b1ef2c288e 100644 --- a/lib/chef/resource/windows_package.rb +++ b/lib/chef/resource/windows_package.rb @@ -24,7 +24,8 @@ class Chef class Resource class WindowsPackage < Chef::Resource::Package - provides :package, platform: "windows" + provides :package, os: "windows" + provides :windows_package, os: "windows" def initialize(name, run_context=nil) super diff --git a/lib/chef/resource/windows_service.rb b/lib/chef/resource/windows_service.rb index 49495117ee..2aec4d6304 100644 --- a/lib/chef/resource/windows_service.rb +++ b/lib/chef/resource/windows_service.rb @@ -25,7 +25,8 @@ class Chef # Until #1773 is resolved, you need to manually specify the windows_service resource # to use action :configure_startup and attribute startup_type - provides :service, platform: "windows" + provides :service, os: "windows" + provides :windows_service, os: "windows" identity_attr :service_name |