Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
- # >>>>>> Path credentials
- # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
- # Set the physical path credentials of the web application (on Basic Settings screen) to Connect As...
- $filter="/system.applicationHost/sites/site[@name='{0}' and @id='1']/application[@path='/{1}']/VirtualDirectory[@path='/']" -f $script:WebSiteName,$appName
- Set-WebConfiguration $filter -Value @{userName="$physicalPathCredentialUserID";password="$physicalPathCredentialPassword"}
- $filter="/system.applicationHost/sites/site[@name='{0}' and @id='1']/application[@path='/{1}']/VirtualDirectory[@path='/']" -f $script:WebSiteName,$appName
- Set-WebConfiguration $filter machine/webroot/appHost -metadata overrideMode -value Allow
- Set-WebConfiguration -Metadata OverrideMode -Value Allow -Filter //windowsAuthentication
- Set-WebConfigurationProperty -PSPath IIS:Sites$WebsiteName$AppName -Filter //windowsAuthentication -Name Enabled -Value $true
- <location path="" overrideMode="Allow">
- <system.webServer>
- <security>
- <authentication>
- <windowsAuthentication>
- </windowsAuthentication>
- </authentication>
- </security>
- </system.webServer>
- </location>
- <authentication>
- <windowsAuthentication enabled="true" />
- </authentication>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement