Skip to main content

Command Palette

Search for a command to run...

🚀Day 32 - Launching your Kubernetes Cluster with Deployment

Published
1 min read
🚀Day 32 - Launching your Kubernetes Cluster with Deployment
S
Hi, I’m Sarika 👋 I’m a QA Engineer with 2+ years of experience in software testing. I have hands-on experience in: * Functional & Regression Testing * API Testing using Postman * Database validation using SQL * Cross-browser testing Currently, I’m focusing on: * Automation Testing using Selenium & Playwright (Java) * Building real-world testing frameworks * End-to-End testing (UI + API + DB) This blog is where I share: * What I learn daily * Real testing scenarios * Practical examples (not just theory) * Interview-focused concepts 🚀 Learning | Building | Sharing Follow me on LinkedIn: https://www.linkedin.com/in/sarika-kamble-3153b3218/

✅What is Deployment in k8s

A Deployment provides a configuration for updates for Pods and ReplicaSets.

You describe a desired state in a Deployment, and the Deployment Controller changes the actual state to the desired state at a controlled rate. You can define Deployments to create new replicas for scaling, or to remove existing Deployments and adopt all their resources with new Deployments.

✅Task-1:

Create one Deployment file to deploy a sample todo-app on K8s using the "Auto-healing" and "Auto-Scaling" features

  • add a deployment.yml file
apiVersion: apps/v1
kind: Deployment
metadata:
  name: node-app-deployment
  labels:
    app: node-app
spec:
  replicas: 3
  selector:
    matchLabels:
      app: node-app
  template:
    metadata:
      labels:
        app: node-app
    spec:
      containers:
        - name : node-todo-app
          image: sarikak/node-app-batch-6
          ports:
            - containerPort: 8000
  • apply the deployment to your k8s (minikube) cluster by command kubectl apply -f deployment.yml

📚Happy Learning :)

More from this blog

S

Sarika Tech Journey

42 posts