Free website hosting #2 – Azure Web Apps

In the second part of this series we take a look at the first free web hosting option in Azure – Wep Apps.

Azure comes with a free hosting tier. This is limited to 1GB and on shared infrastructure, so won’t suit a website needing high performance, however for free hosting this is to be expected.

In this example we’re going to use the same GitHub repo and webpage created in part-1.

Step 1: Create an account or login

If you have an Azure account you can login to the Azure portal using your Microsoft login credentials.

TIP: Learn more about accounts, subscriptions and logins.

To create a free account navigate to https://azure.microsoft.com/en-gb/free/ click the Start for free button, and follow the instructions.

Step 2: Create a web app

Once you have logged into the portal;

  1. Select Create a resource | Web | Web App
  2. Complete the fields
    1. App name must be unique within the AzureWebsites domain, not just your account. A red message will appear if this is not correct.
    2. Choose the subscription where you want the resource saved.
    3. You are going to host a static website, so you can use Windows or Linux
    4. Publish should be set to Code

Step 2b: Create a free service plan

This is the important bit: the App service plan must be F1 (free).

  1. Select App Service plan | Create new
  2. Enter an App Service plan name and select a suitable location.
  3. Click Pricing tier, then under the Dev/Test tab select F1 then click Apply
  4. Click OK to create the new App Service plan.
  5. Click Create to create the web app

To find your new website, click on Home. The website should be at the top of your recent resources list.

Step 3: Add auto-deployment from Git

This step will work from any Git repository, not just GitHub. However GitHub and Azure are both managed by Microsoft, so this feels like a sensible choice.

  • Open the website blade then select Deployment Center
  • On the first page (1 – Source Control) a list of available source options are available. Subsequent steps will reflect the choice made here. We’ll use the same source code from part 1, so select GitHub. You will need to authorise your subscription to access GitHub if you have not already done so.
  • Click Continue
  • Step 2 (Build Provider), select App Service Kudu build server
  • Step 3 (Configure) select the suitable Organisation, Repository and Branch names.
  • Step 4 (Summary), click Continue and the deployment will start.
Toast notifications during deployment
  • Once complete a message will be displayed.
Status update after deployment
  • The website can be access by typing the URL, or from the resource home page Browse button.

Browse with the URL or the link

Done!

Hello free world!

Summary

In summary this approach is no-where near as easy as the steps in part-1. It’s not to say that this is difficult, just that GitHub pages is so simple. Most of the complexity for this site is in the creation of resource groups – and this can be confusing for beginners.

Also, the evolution of the Azure Cloud is moving at such an incredibly fast pace, it can be intimidating or daunting for developers to step in. Fears of features being here-today and gone-tomorrow are quite real – although websites feel pretty safe.

That said, free sites within an Azure website offer far more than just static website hosting. Within this same application you can also host an application with server-side code support (ASP.NET, PHP etc).

Next up – Part 3 – Firebase

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

A WordPress.com Website.

Up ↑

%d bloggers like this: