First of, a Storage account is a container that contains all your storage objects that provides scalability, accessibility, durability and security for your data's
Steps in Providing Storage For The Public Website
step 1 In the portal, search for and select Storage accounts
step 2 Select + Create
step 3 For resource group select new. Give your resource group a name and select OK
STEP 4 Set the Storage account name to publicwebsite. Make sure the storage account name is unique by adding an identifier
STEP 5 Take the defaults for other settings
STEP 6 Select Review and then Create
STEP 7 Wait for the storage account to deploy, and then select Go to resource
This storage requires high availability if there’s a regional outage. Additionally, enable read access to the secondary region, Learn more about storage account redundancy
STEP 1 In the storage account, in the Data management section, select the Redundancy
STEP 2 Ensure Read-access Geo-redundant storage is selected
STEP 3 Review the primary and secondary location information
Information on the public website should be accessible without requiring customers to login
STEP 1 In the storage account, in the Settings section, select the Configuration blade
STEP 2 Ensure the Allow blob anonymous access setting is Enabled.
STEP 3 Be sure to Save your changes
The public website has various images and documents. Create a blob storage container for the content. Learn more about storage containers
STEP 1 In your storage account, in the Data storage section, select the Containers blade
STEP 2 Select + Container
STEP 3 Ensure the Name of the container is public
STEP 4 Select Create
Customers should be able to view the images without being authenticated. Configure anonymous read access for the public container blobs. Learn more about configuring anonymous public access.
STEP 1 Select your public container
STEP 2 On the Overview blade, select Change access level
STEP 3 Ensure the Public access level is Blob (anonymous read access for blobs only)
STEP 4 Select OK
For testing, upload a file to the public container. The type of file doesn’t matter. A small image or text file is a good choice
STEP 1 Ensure you are viewing your container
STEP 2 Select Upload.
STEP 3 Browse to files and select a file. Browse to a file of your choice
STEP 4 Select Upload
STEP 5 Close the upload window, Refresh the page and ensure your file was uploaded
Determine the URL for your uploaded file. Open a browser and test the URL.
STEP 1 Select your uploaded file
STEP 2 On the Overview tab, copy the URL
STEP 3 Paste the URL into a new browser tab
STEP 4 If you have uploaded an image file it will display in the browser. Other file types should be downloaded.
It’s important that the website documents can be restored if they’re deleted. Configure blob soft delete for 21 days. Learn more about soft delete for blobs
STEP 1 Go to the Overview blade of the storage account.
STEP 2 On the Properties page, locate the Blob service section and enable blob soft delete
Ensure the Enable soft delete for blobs is checked, changed the days to 21days,Enable soft delete for containers, Save your changes
If something gets deleted, you need to practice using soft delete to restore the files.
STEP 1 Navigate to your container where you uploaded a file
STEP 2 Select the file you uploaded and then select Delete
STEP 3 Select OK to confirm deleting the file
STEP 4 Select your deleted file, and use the ellipses on the far right, to Undelete the file.
STEP 5 Refresh the container and confirm the file has been restored
It’s important to keep track of the different website product document versions. Learn more about blob versioning.
STEP 1 Go to the Overview blade of the storage account
STEP 2 In the Properties section, locate the Blob service section
STEP 3 Select the Versioning setting
STEP 4 Ensure the Enable versioning for blobs checkbox is checked.
STEP 4 Don’t forget to Save your changes
As you have time experiment with restoring previous blob versions.
STEP 1 Upload another version of your container file. This overwrites your existing file.
STEP 2 Your previous file version is listed on Show deleted blobs page.
Top comments (0)