**using azure cloud service i have prepare a static resume page which is hosted on blob storage ,there is on visitor counter which counter how many time web page is being visited for that i have used azure function which interact with cosmos db account where the counter info is stord **
- GitHub account
- Azure account
- Azure CLI
- .NET Core 3.1 LTS
- Azure Functions Core Tools
- Visual Studio Code
- Visual Code Extensions
-
reference link https://www.youtube.com/watch?v=ieYrBWmkfno (some changes has done )
The front-end is a static site with HTML, CSS, and JavaScript. It's static and has a visitor counter. The visitor counter data fetched via an API call to an Azure Function.
- This article explains how to make an API call with JavaScript and in a simple way how to use it to make an API call.
- Azure storage explorer is a handy tool to use when working with Storage Accounts
- This is how you can deploy static site to blob storage.
The back-end is an HTTP triggered Azure Functions with Cosmos DB input and output binding. The Function is triggered, it retrieves the CosmosDB item, add +1 to it, and saves it and returns its value to the caller.
-
Prerequisites for developing functions with visual code locally.
-
Create a Cosmos DB account via command line or from the portal.
-
Create an HTTP triggered Azure Function in Visual Studio Code.
-
You'll have to enable CORS with Azure Functions locally and once it's deployed to Azure for you website to be able to call it.