class Chef::Resource::WindowsFeature

def run_default_subresource(desired_action)

Returns:
  • (void) -
def run_default_subresource(desired_action)
  raise "Support for Windows feature installation via servermanagercmd.exe has been removed as this support is no longer needed in Windows 2008 R2 and above. You will need to update your recipe to install either via dism or powershell (preferred)." if new_resource.install_method == :windows_feature_servermanagercmd
  declare_resource(new_resource.install_method, new_resource.name) do
    action desired_action
    feature_name new_resource.feature_name
    source new_resource.source if new_resource.source
    all new_resource.all
    timeout new_resource.timeout
    management_tools new_resource.management_tools if new_resource.install_method == :windows_feature_powershell
  end
end