Skip to content

Instantly share code, notes, and snippets.

@zachbonham
Last active December 22, 2015 23:08
Show Gist options
  • Save zachbonham/6544391 to your computer and use it in GitHub Desktop.
Save zachbonham/6544391 to your computer and use it in GitHub Desktop.
Website resource doesn't do anything, error, etc. No documentation in the PDF overview download. However, un-commenting 'Foo' resource will result in an error.
param($machineName = $(hostname))
Configuration SuperAppWeb
{
Node ($machineName)
{
<#
nothing happens when trying to use this resource?
#>
Website DefaultSite
{
Ensure = "Present"
Name = "Default Web Site"
PhysicalPath = "C:\inetpub\wwwroot"
State = "Started"
Requires = "[WindowsFeature]IIS"
}
WindowsFeature AppServer
{
Ensure = "Present"
Name = "Application-Server"
}
WindowsFeature IIS
{
Ensure = "Present"
Name = "Web-Server"
}
WindowsFeature WebServer
{
Ensure = "Present"
Name = "Web-WebServer"
}
WindowsFeature ASP
{
Ensure = "Present"
Name = "Web-Asp-Net45"
}
File "WWW"
{
Ensure="Present"
DestinationPath="c:\WWW"
Type = "Directory"
}
<#
this causes an error - so Website is at least recognized, even if ignored?
Foo Bar
{
Ensure = "Present"
}
#>
}
}
SuperAppWeb
Start-DSCConfiguration $PSScriptRoot\SuperAppWeb -wait -verbose -force
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment