Saturday, February 9, 2019

iis 7 - Redirect incoming requests to specific URLs in IIS 7



I found in IIS HTTP Redirect feature, but I can only redirect all incoming requests to specific destination. Is it possible to redirect incoming requests to specific URLs in IIS? For example:



my.domain.com/blog/about -> other.domainxyz.com/site/about
my.domain.com/blog/post/5 -> other.domainxyz.com/site/5


UPDATE




This is how web.config looks like:
























I havent't found URL Rewrite module among the Role Services although HTTP Redirection is there.


Answer



This rule will redirect SPECIFIC incoming request to specific URL:




















UPDATE:
I have merged them together -- just update it with real URLs:



























No comments:

Post a Comment

linux - How to SSH to ec2 instance in VPC private subnet via NAT server

I have created a VPC in aws with a public subnet and a private subnet. The private subnet does not have direct access to external network. S...