Thursday, April 14, 2011

Windows Azure – Accessing SharePoint hosted site over internet

[This topic assumes that, you are familiar with VM role, SharePoint 2010. You have hosted a SharePoint in Azure using VM role.]
Azure VM role is really a magical thing in Cloud computing introduced by Microsoft. SharePoint server hosting with Azure VM role makes it even more magical.
For making any site publicly accessible, one needs a public IP and public Domain name which you get from ISP (Internet Service Provider). How you can get a public IP and DNS in case of Azure? And more interestingly how it can be used for providing internet access to SharePoint site?
Let’s assume that, using VM role you have hosted a SharePoint server in Azure. Make sure that, you have provided an HTTP INPUT endpoint as port 80 in VM role project of SharePoint. When you specify an input endpoint in Azure, that port specified under the input endpoint is the PUBLIC PORT.
 When you host a cloud service project on Azure, either in staging or production environment; you get DNS name from Azure Management portal. This DNS name is the PUBLIC DNS NAME.

 Let’s say that, you need to host a website in SharePoint present in Azure and provide internet access to it. How do we do it? Let’s start with creating a web site in SharePoint.
1.     Log in to Central administration of SharePoint 2010.

2.     Under “Application Management” select “Manage Web Application” option.
3.     Click “NEW” button present on the ribbon.
4.     On pop up select “Classic mode authentication”. Select radio button labeled as “Create a new IIS site” and input the value in the textbox. Specify any port other than 80. For example – 4555. Click OK to create the web application.
5.     Under “Application Management” select the newly created web application and click on “Authentication Providers”.
6.     For “default” zone, enable anonymous access and click on Save. Then for the same default zone, select anonymous policy as “None – No Policy”. Click Save to proceed further.
7.     Then create a site collection for above created web application and login with primary administrator of the site collection.
8.     Then for above site collection, select “Site Permission” under “User and Permission” menu.
9.     Click on anonymous access. On the pop up window, select “Entire web site” radio button and click OK. This step allowed anonymous access to underlying site collection as well.
10.  Again go to “Central Administration” and click on “Application Management”. Then click on “Manage Web Application”.
11.  Select above created 4555 port web application and click on “Extend” on the ribbon.
12.  On the pop up window, select radio button labeled as “Create new IIS website” and provide meaningful name Ex. Internet Access”. Specify the port as 80. We are specifying port 80 as it is opened as input endpoint in SharePoint VM role. Under host header give the DNS name obtained from your hosted service on Azure portal. Do not enter http://. Enter only name. Public URL will get automatically configured. Then enter zone as Internet. Click OK to create extended web site.
13.  Then click on “Application Management” and select the web application. Then click on “authentication Providers” on the ribbon.
14.  On pop up window click on “Internet” Zone.
15.  On “Edit Authentication” pop up check the checkbox “Anonymous access”. Rest keep as it is and click Ok to save changes.
16.  Then select “Anonymous Policy” for 4555 web site and select zone as Internet and provide value as “None- No Policy”. Save the settings.
17.  This completes the internet configuration of SharePoint site. You can access the site as over internet and outside the domain. In the URL above, part – refers to web application whereas /sites/test refers to site collection that we had created earlier.

Please give food to all my fishes swimming at the bottom. It's fun!! Try it!!
Thanks for reading!!
Happy coding.

No comments:

Post a Comment