Get hands-on and learn how to build and deploy PostgreSQL Database Services and Node.JS appplication on Azure.
If you don't have an Azure subscription, create a free account before you begin.
Perform following steps to Deploy Node.js web application in Azure and connect it to PostgreSQL.
-
Click on Deploy to Azure button above. You will be redirected to custom deployment window of Azure Portal.
-
On Custom deployment page, select Subscription type for Web Application deployment in Basic category.
-
Create new or use existing Resource Group. An Azure resource group is a logical container into which Azure resources like web apps, databases and storage accounts are deployed and managed. Learn more here.
-
Select Location from the available locations for web application deployment.
-
Select App Service Plan. It is pricing model for hosting application, default value is set to F1 which represent free service.
-
The Repo Url is the Github repository url of web application. The default value is set to the current GitHub repository Url which contains sample Node.js application source code which connects with PostgreSQL database created with the ARM template. Leave it as is for this demo
-
Ths Branch is branch name of Github repository where code resides, leave it as is for this demo.
-
Provide the Postgre SQL Compute Unit or leave it as it. Learn more about Compute Unit
-
The Postgre SQL Storage GB is the size of physical memory (in GB) for PostgreSQL Database. Learn more about Storage Unit
-
Administrator Login is username for PostgreSQL Database.
-
Administrator Login Password is password for PostgreSQL Database. It must contain character from three of the following categories – English uppercase letters, English lowercase letters, number (0-9), and non-alphanumeric characters (!, $, #, %).
-
Select Postgre SQL Version for PostgreSQL Database.
-
Select Postgre SQL Location from available locations for PostgreSQL Database.
-
Mark Check I agree to the terms and conditions stated above checkbox.
-
Click on Purchase button.
It will take few minutes to deploy web application and create PostgreSQL Database, after successful deployment you can browse web application.
To clean up the Azure assets:
- Login to the Azure portal.
- Delete the resource group created as part of the deployment – It will have the same name as the prefix used as part of the deployment step. Internally this will delete all the child resources created in Azure.