EelcoKoster / ReverseProxySiteExtension

Repository for Azure WebApps SiteExtention Reverse Proxy
35 stars 13 forks source link

How do you debug this #1

Open sjkp opened 9 years ago

sjkp commented 9 years ago

I tried to install the extension and did the following rewrite:

<rewrite>
  <rules>
    <rule name="ProxyExample" stopProcessing="true">
      <match url="^ch9/?(.*)" />
      <action type="Rewrite" url="http://channel9.msdn.com/{R:1}" />
    </rule>
  </rules>
</rewrite>

But I get: The resource you are looking for has been removed, had its name changed, or is temporarily unavailable. So a 404.

When i browse my site on http://sjkprev.azurewebsites.net/ch9

Am I misunderstanding something? Or is the extension not working as it should. I had to reboot the site after installing it for the config page to work. I'm running on a Basic instance.

EelcoKoster commented 9 years ago

Hi Simon,

Thanks for reaching out to me, and trying my site extension. Did you install it using the Kudu console or via the preview portal (portal.azure.com)?

I noticed that sometimes (not always!?!?) my extension isn't installed correctly when you use the Kudu site. The extension tries to update the applicationHost.config file to enable the proxy.

What worked for me was to kill the w3wp.exe process using the Kudu site. To do this go to http://sjkprev.scm.azurewebsites.net/ProcessExplorer/ Right click on w3wp.exe (without scm) and click on "Kill" It will automatically start a new process when you try to access a page on your site (and also update your applicationHost.config enabling your proxy). It should work now...

BTW: I noticed Channel9 now enforces https and will redirect you to their domain. You should update your rewrite rule to use the httpS url instead of the http url.

One again thanks for reaching out. I will try to smoothing this out. I would like to know if my workaround worked for you.

sjkp commented 9 years ago

Thanks it works now :+1:

nickdima commented 8 years ago

@EelcoKoster is the extension still working? I installed it from the Azure portal and added the rewrite rule but it acts as a redirect. What should I do? Thanks!

sjkp commented 8 years ago

My site where I use it is still working.