Created
July 9, 2013 10:48
-
-
Save JamesDawson/5956472 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| configuration SimpleConfig2 | |
| { | |
| node LAB-WEB01 | |
| { | |
| File MarkerFile | |
| { | |
| DestinationPath = 'C:\deployed.txt' | |
| Contents = "" | |
| Requires = "[Group]FooGroup","[Registry]EnableRdp" | |
| } | |
| Group FooGroup | |
| { | |
| Ensure = "Present" | |
| Name = "Foo" | |
| Members = @("foobar") | |
| Requires = "[User]FooBarUser" | |
| } | |
| User FooBarUser | |
| { | |
| Ensure = "Present" | |
| UserName = "foobar" | |
| Description = "an important service account" | |
| FullName = "FooBar Service Account" | |
| Disabled = $False | |
| Password = New-Object System.Management.Automation.PSCredential ("username", (ConvertTo-SecureString "P4ssw0rd1" -AsPlainText -Force)) | |
| PasswordNeverExpires = $True | |
| } | |
| Registry EnableRdp | |
| { | |
| Key = "HKLM:SYSTEM\CurrentControlSet\Control\Terminal Server"; | |
| ValueName = "fDenyTSConnections"; | |
| ValueData = "0"; | |
| ValueType = "DWord"; | |
| } | |
| Script SetTimezone | |
| { | |
| GetScript = { return @{ Timezone = ("{0}" -f (tzutil.exe /g)) } } | |
| TestScript = { return (tzutil.exe /g) -ieq "GMT Standard Time" } | |
| SetScript = { tzutil.exe /s "GMT Standard Time" } | |
| } | |
| } | |
| } | |
| SimpleConfig2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment