问题
I am trying to use an IIS reverse proxy to make my TFS server accessible to a different group of users on the network.
I have anonymous authentication turned on on the reverse proxy server (URL Rewrite and ARR). Whenever I try to connect to the TFS server I get a 401, and typing the password correctly in doesn't work.
I have tried both of these Rewrite URLs:
http://192.168.1.85:8080/{R:0}
http://192.168.1.85:8080/{R:1}
Both are producing the 401, though. I have tried turning Windows Authentication and Basic Authentication on and off. Neither of those work, either. TFS is installed with a default configuration.
Any ideas? I know folks are doing this to expose TFS, so hopefully there is an easy way to get it to work.
回答1:
Typically TFS would be installed in a virtual directory "tfs" at port 8080. Therefore if you have a typical IIS setup, you should change your rewrite URL from:
http://192.168.1.85:8080/{R:0}
to
http://192.168.1.85:8080/tfs/
Chances are though the above by itself won't be enough since all of your relative links will be broken therefore to fix this, what I recommend is this for your match url patten:
^(tfs/)?(.*)?
and then this for your rewrite pattern:
http://192.168.1.85:8080/tfs/{R:2}
I hope this helps.
来源:https://stackoverflow.com/questions/23720447/tfs-2013-not-working-with-iis-reverse-proxy