Skip to content

Demonstrates how to use Azure Storage SDK to upload images to Blob Storage from an Express.js application in Node.js

License

Notifications You must be signed in to change notification settings

aferlim/storage-blob-upload-from-webapp-node

 
 

Repository files navigation

Azure Storage Blob Upload from a Node.js Web Application

This sample demonstrates how to use the Azure Storage SDK in the context of an Express application to upload images into Azure Blob Storage.

Getting started

Clone the repository to your machine:

git clone https://github.com/Azure-Samples/storage-blob-upload-from-webapp-node.git

Change into the storage-blob-upload-from-webapp-node folder:

cd storage-blob-upload-from-webapp-node

Install dependencies via npm:

npm install

Adding a connection string

Navigate to the Azure Portal and copy the connection string from your storage account (under Settings > Access keys) in to the .env.example file. Once you have pasted your connection string in to the file, rename the file from .env.example to .env.

Running the sample

Start the server:

npm start

Navigate to http://localhost:3000 and upload an image to blob storage.

You can use the Azure Storage Explorer to view blob containers and verify your upload is successful.

About

Demonstrates how to use Azure Storage SDK to upload images to Blob Storage from an Express.js application in Node.js

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 75.5%
  • HTML 21.4%
  • CSS 3.1%