If you ever tried to configure SSL host headers for your IIS7 sites, you already know that this can be done from the IIS management console only for the very first site. If you try to add the SSL binding for another site, the console will prevent you from doing so.
How people usually solve this problem is they use the appcmd commandline tool to add the SSL binding manually for other sites. First, you map add SSL to the very first of your sites manually and then use a script to map another site:
However, there’s actually much simpler way to add the SSL binding. It involves manually editing the IIS configuration file, which is C:\Windows\System32\intersrv\config\applicationHost.config. The IIS uses this file to store its configuration.
Edit this file, find a <site> node which refers to your site, it should look like this:
Just modify this to: