Azure

5 Mins Read

Kickstart Your Kubernetes Journey with AKS: From Cluster Creation to Pod Management

Voiced by Amazon Polly

🧭 Introduction

In the cloud-native world, Kubernetes has become the de facto standard for deploying, scaling, and managing containerized applications. Whether you’re a developer, system admin, or DevOps engineer, learning Kubernetes is a must-have skill.

In this blog, we will cover:

  • What is Kubernetes and AKS?
  • How to create your first Kubernetes cluster on Azure
  • The core building block: Pods
  • Hands-on labs: Namespaces, Pod creation, YAML, labels, and interactive access

Let’s break this down with theory + practical labs to give you a full-circle understanding! 🔄

Freedom Month Sale — Upgrade Your Skills, Save Big!

  • Up to 80% OFF AWS Courses
  • Up to 30% OFF Microsoft Certs
Act Fast!

🌩️ What is Azure Kubernetes Service (AKS)?

Azure Kubernetes Service (AKS) is a managed Kubernetes service offered by Microsoft Azure. It simplifies the deployment, management, and operations of Kubernetes clusters by:

  • Handling control plane management
  • Integrating with Azure AD, monitoring, and logging
  • Providing automatic updates and scaling
  • Reducing operational overhead for teams

💡 With AKS, you don’t need to worry about manually setting up the Kubernetes master components—it’s managed for you!

⚙️ Step-by-Step: Creating Your First AKS Cluster

🚀 Step 1: Launch Azure Cloud Shell

Azure Cloud Shell is a browser-based terminal that comes preconfigured with the Azure CLI.

  • Open Azure Portal.
  • Click on the Cloud Shell icon in the top-right corner.
  • Choose Bash, wait for initialization.

🔧 Step 2: Set Environment Variables

RESOURCE_GROUP=”K8S-RG”

CLUSTER_NAME=”aks-cluster”

✅ These variables help in reusability and better scripting practices.

📌 Make sure Resource Group already exists

 

☸️ Step 3: Create the AKS Cluster

 

 

This command does the following:

  • Creates a managed Kubernetes cluster with 2 worker nodes
  • Uses VM size Standard_DS2_v2 (2 vCPUs, 7GB RAM)
  • Generates SSH keys for secure access

⏳ Takes a few minutes. After completion, you’ll get details like fqdn, kubeConfig path, and more.

 

🔗 Step 4: Connect to Your AKS Cluster

Get a list of Kubernetes Clusters

 

📌 This downloads the kubeconfig and merges it with your local Kubernetes config, allowing you to use kubectl commands.

✅ Step 5: Verify the Cluster Nodes

 

📌 This confirms the cluster is active and nodes are ready.

📦 Understanding Kubernetes Pods

🔍 What is a Pod?

A Pod is the smallest deployable unit in Kubernetes. It wraps one or more containers, networking, storage, and metadata into a single logical unit.

Think of a Pod as a single virtual machine, but designed for containers.

🧱 Pod Architecture

  • Containers: One or more (most often one)
  • Shared IP: Containers share the same IP and port space
  • Volumes: Shared storage volumes across containers in a Pod

📊 Pod Types

Type Use Case
Single-container Most applications (e.g., NGINX, Node.js apps)
Multi-container Sidecar patterns like log collectors, proxies

 

🔁 Pod Lifecycle

Phase Description
Pending Pod created but containers not started
Running Containers running normally
Succeeded Containers completed successfully
Failed Containers terminated with errors
Unknown State could not be determined

⚡ Init Containers

Init containers run before app containers start. Used for:

  • Pre-loading configs
  • Waiting for a database to be ready
  • Running setup tasks

📌 They run sequentially and must complete before the main app starts.

🧪 Lab : Kubernetes Pods

⚙️ Task 1: Create Pod via Command Line

 

 

You’ve created a pod running the NGINX web server.

📝 Task 2: Create Pod via YAML

Why YAML?
YAML provides declarative configuration, making it reusable, version-controlled, and infrastructure-as-code (IaC) friendly.

Create the file:

 

Paste this config:

Apply it:

 

 

 

🔧 Task 3: Exec into Pod

🚪 Why Use kubectl exec?

You may need to:

  • Debug issues inside a pod
  • Install utilities for testing
  • Inspect config files or logs

Type exit to return.

🧠 Conclusion

You’ve now completed a foundational journey in Kubernetes using AKS, learning how to provision clusters, manage pods, and interact with workloads using both commands and YAML. This forms the base for running production-grade containerized applications on Azure.

To advance your career and solidify your expertise, consider these next steps:

🚀 With these certifications, you’ll be fully prepared to design, implement, and scale enterprise-grade cloud-native DevOps solutions powered by Kubernetes and Azure AKS.

 

📚 Further Reading & Official Reference

For more information, best practices, and advanced use cases, visit the official Kubernetes documentation:

🔗 https://kubernetes.io

For Azure-specific Kubernetes documentation (AKS):

🔗 https://learn.microsoft.com/azure/aks

Freedom Month Sale — Discounts That Set You Free!

  • Up to 80% OFF AWS Courses
  • Up to 30% OFF Microsoft Certs
Act Fast!

About CloudThat

CloudThat is an award-winning company and the first in India to offer cloud training and consulting services worldwide. As a Microsoft Solutions Partner, AWS Advanced Tier Training Partner, and Google Cloud Platform Partner, CloudThat has empowered over 850,000 professionals through 600+ cloud certifications winning global recognition for its training excellence including 20 MCT Trainers in Microsoft’s Global Top 100 and an impressive 12 awards in the last 8 years. CloudThat specializes in Cloud Migration, Data Platforms, DevOps, IoT, and cutting-edge technologies like Gen AI & AI/ML. It has delivered over 500 consulting projects for 250+ organizations in 30+ countries as it continues to empower professionals and enterprises to thrive in the digital-first world.

Share

Comments

    Click to Comment

Get The Most Out Of Us

Our support doesn't end here. We have monthly newsletters, study guides, practice questions, and more to assist you in upgrading your cloud career. Subscribe to get them all!