Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Static Web hosting using Azure Storage

2025-04-01 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

A new relative feature in Azure is the ability to host static Web sites in Azure storage. This will be convenient if you only need to host a simple Web site cheaply and with little configuration. Although the site code needs to be static, you can use some Azure resources to execute the back-end process. Next I'll show you how to use Azure storage to host a simple static web page.

Configure Storage Account

First, we need a Storage Account. Storage Account needs to be of type "General purpose V2". We can use the portal, PowerShell, or CLI to create one:

When we have created the Storage Account, we need to find the static website in the settings:

Click Enable under the title of the static website. Then add the name of the html file. Usually we call it index.html. You can also add an error page if desired. After entering the information, click Save:

When the save is complete, you will see the new web address:

Upload website

After you click save, a new container is created for you in the blob store in your storage account. The new container is called $web. It is a system container and the place where the website is stored.

We can upload our html website in many ways, and here I upload it using portal:

Click "upload" and select the index.html file we have prepared to upload:

After the file is uploaded successfully, we will visit this site by our browser:

A static web page hosted in an Azure storage account. If you want to make URL better. You can use the DNS host provider to create CNAME records.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report