Skip to content

dylanratcliffe1/winoptionalfeature

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SUMMARY:

This puppet module creates a new defined type 'winoptionalfeature'. This can be called within any class to install/remove windows features from a non Windows Server OS based on their ID string ex: 'Web-Server' or a comma seperated list of feature IDs ex: 'Telnet-Client,Telnet-Server'

The functionality is simply a wrapper to the powershell cmdlets 'Enable-WindowsOptionalFeature' and 'Disable-WindowsOptionalFeature'.

Inspired from puppet module: https://forge.puppetlabs.com/opentable/windows_feature

DEPENDENCIES:

USAGE:

Param: title
Description: The text ID of the feature to install
Required: Yes
Values: ID string ex: 'Web-Server' or a comma seperated list of feature IDs ex: 'Telnet-Client,Telnet-Server' 
Default: -none-

Param: ensure
Description: Whether to install or remove the feature
Required: Yes
Values: 'present' -or- 'absent'
Default: -none-

Param: restart
Description: Whether to restart the computer after feature installation.
Required: No
Values: true -or- false
Default: false

Param: logpath
Description: file in which to log the installation output
Required: No
Values: Valid filepath, puppet escaped. Ex: "c:\\featureinstall.log"
Default: -none-

class install-winfeatures{    
    winoptionalfeature{'[TITLE]':
        ensure => '[PRESENT/ABSENT]',
        logpath => "[FILEPATH]",
        restart => [TRUE/FALSE],
    }
}

EXAMPLES:

**INSTALL WEB SERVER ROLE**

class install-winfeatures{    
    winoptionalfeature{'IIS-WebServerRole':
        ensure => 'present',
        logpath => "C:\\featureinstall.log",
        restart => false,
    }
}

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages