Cognitive Services Tutorial #1: Create a storage account

Objectives
In this tutorial, you will learn how to:
– Create a storage account and storage containers using the Azure Portal
– Write a Node.js app in Visual Studio Code and deploy it to Azure using Git
– Read and write blobs and attach metadata to them
– Use the Computer Vision API to extract information from images and generate thumbnails
– Use the cross-platform Microsoft Azure Storage Explorer to work with Azure Storage

Prerequisites
The following are required to complete this tutorial:
– An active Microsoft Azure subscription.
– Microsoft Azure Storage Explorer
– Visual Studio Code
– Git version 2.0 or higher
– Node.js version 4 or higher

Tutorial 1: Create a storage account
1. Open the Azure Portal in your browser. If you asked to log in, do so using your Microsoft account.

2. The first step in using Azure Storage is to create a storage account. To create a storage account, click +Create a resource in the ribbon on the left. Then click Storage, followed by Storage account.

3. In the ensuing “Create storage account” blade, enter a name for the new storage account in Name field. The name is important, because it forms one part of the URL through which blobs created under this account are accessed.
Once you have a name that Azure will accept (as indicated by the green check mark in the Name field), make sure Resource manager is selected as the deployment model and General purpose is selected as the account kind. Then select Create new under Resource group and type “IntellipixResourceGroup” (without quotation marks) into the box below to the new resource group that will be created for the storage account. Finish up by selecting the location nearest you in the Location box, and clicking the Create button at the bottom of the blade to create the new storage account.

4. Once the storage account has been created, click Resource groups in the ribbon on the left. Then click the “IntellipixResourceGroup” resource group, and in the blade that opens for the resource group, click the storage account you just created.

5. In the blade for the storage account, click Blobs to view a list of containers associated with this account.

6. The storage account currently has no containers. Before you can create a blob, you must create a container to store it in. Click + Container to create a new container. Type “photo” (without quotation marks) in to the Name field and select Blob as the Access type. Then click OK to create a container named “photos“.

7. Repeat this process to create a container name “thumbnails“, once more ensuring that the container’s Access type is set to Blob.

8. Confirm that both containers appear in the list of containers for this storage account, and that the names are spelled correctly.

9. Click Access keys in the menu on the left side of the storage-account blade, and then click the Copy button next to KEY for key1. Paste this access key into your favorite text editor for later use.

You have now created a storage account to hold images uploaded to the app you’re going to build, and containers to store the images in. Note that you could create these containers from within the app. Whether to create them programmatically or create them as part of the provisioning process is a choice that’s left up to app developers.

One Comment on “Cognitive Services Tutorial #1: Create a storage account”

Leave a Reply

Your email address will not be published. Required fields are marked *