Skip to content

Instantly share code, notes, and snippets.

@guimar86
Last active March 27, 2022 10:25
Show Gist options
  • Save guimar86/44375e8315fad95c1ae6103531a3cef0 to your computer and use it in GitHub Desktop.
Save guimar86/44375e8315fad95c1ae6103531a3cef0 to your computer and use it in GitHub Desktop.

Verify IIS Configuration

This is a powershell script

if((Get-WindowsFeature Web-Server).InstallState -ne "Installed"){
  Write-Host "Failed, IIS not installed " - ForegroundColor Red
  break
}else{
  Write-Host "Pass IIS is installed " -ForegroundColor Green
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment