Thursday, 5 January 2017

Window Azure ,Test HTTPS for your custom domain in Window Azure. And Navigate to custom domain using Kudu debug console for your app.

================
for example we want to set https:// ( SLS  Certificate) to my Custom domain from azure then the process is.
=============
If you still want to allow HTTP access to your app, skip this step. App Service does not enforce HTTPS, so visitors can still access your app using HTTP. If you want to enforce HTTPS for your app, you can define a rewrite rule in the web.config file for your app. Every App Service app has this file, regardless of the language framework of your app.




Follow these steps:
  1. Navigate to the Kudu debug console for your app. Its address is https://<appname>.scm.azurewebsites.net/DebugConsole.
  2.  for Example- https://satyabrata.scm.azurewebsites.net/DebugConsole
  3. After that we login using azure uid and password. Next-
  4. In the debug console, CD to D:\home\site\wwwroot.
  5. Open web.config by clicking the pencil button.

  1. If you deploy your app with Visual Studio or Git, App Service automatically generates the appropriate web.config for your .NET, PHP, Node.js, or Python app in the application root. If web.config doesn't exist, run touch web.config in the web-based command prompt to create it. Or, you can create it in your local project and redeploy your code.
  2. If you had to create a web.config, copy the following code into it and save it. If you opened an existing web.config, then you just need to copy the entire <rule> tag into your web.config'sconfiguration/system.webServer/rewrite/rules element.
    Copy
     <?xml version="1.0" encoding="UTF-8"?>
     <configuration>
       <system.webServer>
         <rewrite>
           <rules>
             <!-- BEGIN rule TAG FOR HTTPS REDIRECT -->
             <rule name="Force HTTPS" enabled="true">
               <match url="(.*)" ignoreCase="false" />
               <conditions>
                 <add input="{HTTPS}" pattern="off" />
               </conditions>
               <action type="Redirect" url="https://{HTTP_HOST}/{R:1}" appendQueryString="true" redirectType="Permanent" />
             </rule>
             <!-- END rule TAG FOR HTTPS REDIRECT -->
           </rules>
         </rewrite>
       </system.webServer>
     </configuration>
    
    This rule returns an HTTP 301 (permanent redire

No comments:

Post a Comment