标签:
#安装IIS、.NetFramework 3.5 Import-Module servermanager Get-WindowsFeature web-* | ? {$_.Name -ne "Web-WHC" -and $_.Name -ne "Web-Ftp-Server" -and $_.Name -ne "Web-Ftp-Ext" -and $_.Name -ne "Web-Ftp-Service" -and $_.Name -ne "Web-Custom-Logging" -and $_.Name -ne "Web-ODBC-Logging" -and $_.Name -ne "Web-Client-Auth" -and $_.Name -ne "Web-Cert-Auth" -and $_.Name -ne "Web-DAV-Publishing"} | Add-WindowsFeature Add-WindowsFeature NET-Framework,WAS -IncludeAllSubFeature #新建wwwroot目录 cmd /c "md D:\wwwroot" #删除默认站点 Import-Module webadministration Remove-Website -Name "Default Web Site" #更改IISLog位置到 D:\IISLog cmd /c "md D:\IISlog" $iislogdir = "D:\IISLog" Set-WebConfigurationProperty "/system.applicationHost/sites/siteDefaults" -name logfile.directory -value $iislogdir
IIS配置(安装IIS、.Net、更改IIS Log目录位置)
标签:
原文地址:http://www.cnblogs.com/dreamer-fish/p/4610952.html