How do I map IIS virtual directory to a subdomain?

狂风中的少年 提交于 2019-12-24 21:17:30

问题


Currently, I have a website mapping as following

http://subdomain.domain.com/<virtualdir> to http://<IP Address>/<virtualdir> 

I want the virtual directory to be accessed with just the subdomain:

http://subdomain.domain.com/ 

so that it points to http://<IP Address>/<virtualdir>

Im using IIS 10, windows server 2016.

What are my possible options?


回答1:


If I understand your question correctly you want http://subdomain.domain.com/ to be accessible by the plain URL http://subdomain.domain.com. If that is the case you want to go into your IIS: 1. select 2. right click 3. convert to application

You can then give it bindings just like your base website with your desired DNS entry.

Side note; You can then either remove your binding from the base site that you want on the or give it the same address of http://subdomain.domain.com but some other port so it would be http://subdomain.domain.com:8080 to access the and http://subdomain.domain.com for the original content at the base site



来源:https://stackoverflow.com/questions/49005921/how-do-i-map-iis-virtual-directory-to-a-subdomain

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!