I’m currently learning Powershell, So I started gently with easy script. Below, you can find one let you create some IIS8 website easily & fastly. This powershell script create the Application Pool, website, directory and an index.html :
Write-Host "Welcome in PSWebsiteCreator by Alexnogard from alexnogard.com" -ForegroundColor Red -BackgroundColor White $SiteName = Read-Host "Please enter the site name" $PhysPath = Read-Host "Please enter path pointing to your website (e.g. : c:\mywebsite)" $BindingIP = Read-Host "Enter an Ip Address, or leave empty" $BindingPort = Read-Host "Enter port you wanna use (e.g. : 81) " $AppPool = Read-Host "You ApplicationPool Name (e.g. : Default Web Site)" s New-Item $PhysPath -type directory New-Item $PhysPath\index.html -type file -force -value "<center>Coucou petite perruche</center>" New-WebAppPool -Name $AppPool New-Website -Name $SiteName -ApplicationPool FirstWebsiteAppPool -Force -PhysicalPath $PhysPath -Port $BindingPort
See you soon !