View the binding for the website in IIS
To view the binding, you need to call Get-WebBinding API.
Import-Module WebAdministration
Get-WebBinding -Name 'default web site'
Explanation:
1. We import the WebAdministration PS module into memory so that we can call any of the API that interacts with IIS.
2. Call Get-WebBinding to retrieve the binding for the "default web site" (you might have website that is different name).
In case you need to find out all website names, please run the following codes:
Get-ChildItem IIS:\Sites | select name
Import-Module WebAdministration
Get-WebBinding -Name 'default web site'
Explanation:
1. We import the WebAdministration PS module into memory so that we can call any of the API that interacts with IIS.
2. Call Get-WebBinding to retrieve the binding for the "default web site" (you might have website that is different name).
In case you need to find out all website names, please run the following codes:
Get-ChildItem IIS:\Sites | select name
Comments
Post a Comment