Static Websites
Static Websites as everyone knows, are displayed in a web browser exactly as it is stored. It is very light weight and only requires a web server for functioning. It is helpful for use cases such as blogs, restaurant menus etc. where the content remains fixed. As the name suggests these websites do not change, it remains "static" for every viewer of the site. Compared to dynamic websites, they are quick to set up, cost-effective and do not have the overhead of high-level programming and database design. In this blog we will be discussing how to host a static website in Azure Storage.
Hosting A Static Website Using Azure Storage
1. Log into azure portal.
2. Create a storage account.
3. Once deployment is completed, go to static website within the storage account. Enable it and update the index document name and the error document name with the names from your website files.
4. Once its saved a primary endpoint is created which is the basically the url of the website. If we access the url now we get an error as in image below because we have not uploaded the website files in Azure.
5. When we go back to the portal there is a container provisioned by azure for storing the files for the website called $web. On clicking the $web we are taken to the container where we upload the files as in the below image.
6. Once the files are successfully uploaded, hitting the endpoint again will load our website.
Thanks for reading through and I hope you find my little blog informative!