Azure App Services: How to Create an App and Upload Content

tjasper

Oluwaloseyi Oluwatofunmi Emmanuel

Posted on November 11, 2024

Azure App Services: How to Create an App and Upload Content

What is Azure App Service?

Azure App Service is a platform-as-a-service (PaaS) offering in Microsoft Azure that allows developers to build, deploy, and scale web applications, mobile backends, RESTful APIs, and more. With App Service, you can run applications on a secure, scalable cloud platform without worrying about the underlying infrastructure. It supports multiple programming languages and frameworks, including .NET, Node.js, Java, Python, PHP, and Ruby.

Requirements to create an App Service Application in Azure

  1. Azure CLI
  2. An Azure account
  3. A text-based user interface (Powershell or Terminal)
  4. A resource group
  5. An App Service plan (Where the computing resources are hosted)
  6. The webapp itself

In this guide, we'll walk you through creating an App Service application and uploading your content step-by-step. By the end, you’ll have a fully deployed app, ready to serve your audience. Perfect for beginners and experienced developers alike, this tutorial will help you get your app live on Azure quickly and efficiently.

Let’s get started with creating and deploying your app on Azure App Service!


Step-by-Step Guide: Building and Uploading Content to an Azure App Service

Step 1: Download and install Azure CLI

  • Go to your browser and search Azure CLI.

browser and search

  • Navigate to the install section and select your operating system.

select your operating system

  • Make sure to install it.

Step 2: Access you Azure account with PowerShell

  • Run your windows PowerShell as administrator

PowerShell

  • Use the command below to login to your Azure account.
az login  
Enter fullscreen mode Exit fullscreen mode
  • Use az login --tenant and parent management group under subscription to login as a tenant of the account.

Azure login

Step 3: Create your Resource group

  • To create a resource group we use the code:
az group create --name NGtourRG --location eastus
Enter fullscreen mode Exit fullscreen mode

Where NGtourRG is the Name of the resource group and eastus is the Region.

Resource group

Step 4: Create an App Service Plan

  • To create an app service plan we use the code:
az appservice plan create --name NGtourPlan --resource-group NGtourRG
Enter fullscreen mode Exit fullscreen mode

Where NGtourPlan is the App Service Plan

App Service Plan

App Service Plan

  • If there is a problem with the Region change using --location and the new location name.

Step 5: Create an empty Web App that will host our code

  • To create a web app we enter the code:
az webapp create --name NGtourWebApp --resource-group NGtourRG --plan NGtourPlan 
Enter fullscreen mode Exit fullscreen mode

webapp
webapp

  • Go to azure portal in the App Service section to ensure the web App was successfully created.

azure portal
azure portal

  • click on the webapp NGtourWebApp you created.
  • In the overview tab select Default domain.

NGtourWebApp

  • Ensure the web App is running and waiting for content

Webpage

Step 6: Deploy content(code) to the application

  • In the azure portal search Advanced Tools.
  • Select it and click Go.

Advanced Tools
Note: it opens up a browser(KuduPlus) this contains tools for uploading our code

  • In the browser click Debug console
  • Select CMD from the dropdown

KuduPlus

  • Select the Site folder
    Site

  • Select the wwwroot folder
    wwwroot

  • Click on the Pencile icon
    Pencile icon

  • Paste in your code and click Save
    Paste code

  • Reopen the Default domain and notice your content have been uploaded.

NGtourApp

By following these steps, you've successfully created an Azure App Service application and uploaded your content(code), bringing your Web app live on a reliable, scalable cloud platform. With Azure App Service, managing and deploying web applications becomes easier and more efficient, giving you more time to focus on enhancing your app’s features and user experience. Now, you’re equipped to build, scale, and maintain applications in Azure with confidence.


Thank you for reading my blog.😊😊

If you need further assistance, feel free to reach out in the comment or hit me up on Twitter. You can also follow me on GitHub. My DM's are open and love discussions on cloud topics!😁

💖 💪 🙅 🚩
tjasper
Oluwaloseyi Oluwatofunmi Emmanuel

Posted on November 11, 2024

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related