DEV Community

Cover image for Deploy an Application on AKS Cluster Using A Kubernetes Manifest File
Abisola Adesegun
Abisola Adesegun

Posted on

1

Deploy an Application on AKS Cluster Using A Kubernetes Manifest File

Table of contents
Step 1: Login to Azure
Step 2: Create Resource group and AKS cluster
Step 3: Connect to AKS Cluster
Step 4: Create a yaml file and deploy the application
Step 5: Verify the deployment
Step 6: Access the Application
Step 7: Clean up

To deploy an application on an Azure Kubernetes Service (AKS) cluster using a Kubernetes manifest file, follow these steps:

Prerequisites:

  • Azure CLI installed.

  • kubectl installed.

  • You have an AKS cluster up and running.

  • Kubernetes manifest file ready (YAML file).

Step 1: Login to Azure

  • First, log in to your Azure account and connect to your AKS cluster: Copy code

Image description

  • Once authenticated, set the subscription

Image description

Step 2: Create Resource group and AKS cluster

  • Create RG

Image description

  • Create an AKS cluster

Image description

Step 3: Connect to AKS Cluster

Image description

Step 4: Create a yaml file and deploy the application

  • Create a yaml file

Image description

  • Deploy the application by running the following command to apply the manifest file to the AKS cluster

Image description

Step 5: Verify the deployment

  • Check the status of the pods:

Image description

  • Check the status of the service and get the external IP

Image description

After a few moments, you should see an external IP address under the EXTERNAL-IP column. You can use this IP to access the Nginx application via a web browser.

Step 6: Access the Application

  • Once the service is deployed, access the application using the external IP of the LoadBalancer:

Using code
http://

Image description

  • Explore the application

Image description

Image description

Step 7: Clean up
using the following command

Image description

Sentry image

Hands-on debugging session: instrument, monitor, and fix

Join Lazar for a hands-on session where you’ll build it, break it, debug it, and fix it. You’ll set up Sentry, track errors, use Session Replay and Tracing, and leverage some good ol’ AI to find and fix issues fast.

RSVP here →

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay