WCF service on root of IIS host

2019-07-09 00:41发布

问题:

How would I set up a WCF service hosted in IIS on the root of the domain? i.e. http://www.example.com instead of http://www.example.com/Service1.svc/

I can't figure out how to get rid of the service filename.

回答1:

Add Service1.svc to the default document names in IIS and move it to the top of the list.



回答2:

Is that what you really want? If there is any slight chance that you might want a second service from the same domain someday, you'll wish that you hadn't exposed the root publicly that way.



标签: wcf iis service