Create Kubernetes Cluster in Azure

Everton Araújo
3 min readMar 16, 2022

Today I’m starting a new stage here at Medium and I continue with the agenda focused more on Azure, it’s where I work the most on a day-to-day basis. Today I will show you a basic installation of AKS (Azure Kubernetes Services).

AKS logo
We will make a basic architecture for understanding AKS

We will do the first installation via the azure portal and then at another time we will approach via terraform.

Azure Portal
Kubernetes Services

To start installation, have two options :

  • Create a kubernetes cluster
  • Add a Kubernetes cluster with Azure ARC

Select — Create Kubernetes cluster

I’ll explain it in steps here, to make it easier.

Project details

  1. Select your subscription;
  2. Select your resource group or create new
  3. Cluster Details
Cluster preset configuration

I will do the cheapest setup for dev.
In case of starting projects I recommend the Standard version. But remembering each case a case.

Select Dev/Test($) : It´s best cost to experimenting with AKS or deploying a test app

  1. Kubernetes cluster name : Select Name AKS
  2. Region — Select your region — (Recommends EAST US). $
  3. Availability Zones — It’s case is a test deploy. (NO).
  4. Kubernetes Version — 1.21.9(DEFAULT)
  5. API Server Availability — 99,5% ( COST $).

Following down the configuration of the Primary node can pool that could not show on the full screen.

  1. Node Size: Testing ( B2S ou D2as_vr4)
  2. Scale method ( Manual) — Testing app deploy.
  3. Node count — ( 3) It’s kubernetes default nodes

Click in next: node pools

I recommend as best practices, click next and go to Tags.

Select button blue (Create)

the installation takes at least 15 minutes, you will have a good coffee.

Finish…. YEAHHHHHHHHHH

Nice Everton….after installation is finished how do I connect.
I answer you: There are two options (Azure-cli or Cloudshell Azure).

I’ll do it via azure-cli hahahaa….
If you want to install — https://docs.microsoft.com/en-us/cli/azure/install-azure-cli

start setup via azure cli

Set your subscription

az-account set — subscription

Insert Credentials

az aks get-credentials — resource-group aks-everton — name everton-aks

Ps: Remembering that the kubeconfig file if you use windows can be c:\users\everton\.kube\config.
That’s an example.

To check if the nodes are working, I already taught last time.
But it doesn’t hurt to teach again because I’m a nice guy!

If you don’t have kubectl installed, type the command: az aks install-cli

Anyway, this stage is over and I count on the feedbacks and if you can share my post I would really appreciate it. Great day for everyone!!

--

--