🔧 DevOps Interview Questions

Master DevOps interviews with questions on CI/CD, Docker, Kubernetes, Infrastructure as Code, and monitoring

Explain the CI/CD pipeline and implement a GitHub Actions workflow

Medium

CI/CD (Continuous Integration/Continuous Deployment) automates the software delivery process. CI merges code changes frequently and runs automated tests. CD automatically deploys to production.

Key Components:

  • Source Control: Git, GitHub, GitLab
  • Build: Compile code, run tests
  • Test: Unit, integration, e2e tests
  • Deploy: Push to staging/production
  • Monitor: Track application health
YAML

Explain Docker and write a multi-stage Dockerfile

Medium

Docker containerizes applications with their dependencies, ensuring consistency across environments. Multi-stage builds optimize image size by separating build and runtime dependencies.

Dockerfile
YAML
bash

Explain Kubernetes architecture and write deployment manifests

Hard

Kubernetes (K8s) orchestrates containerized applications at scale. It manages deployment, scaling, and operations of application containers across clusters of hosts.

Key Components:

  • Control Plane: API Server, Scheduler, Controller Manager, etcd
  • Worker Nodes: Kubelet, Container Runtime, Kube-proxy
  • Pods: Smallest deployable units
  • Services: Stable network endpoints
  • Deployments: Declarative updates for Pods
YAML
bash

Explain Infrastructure as Code with Terraform

Hard

Infrastructure as Code (IaC) manages infrastructure through code rather than manual processes. Terraform is a popular IaC tool that supports multiple cloud providers.

HCL
bash

Explain monitoring and observability with Prometheus and Grafana

Medium

Monitoring tracks system health through metrics. Observability provides deeper insights through metrics, logs, and traces. Prometheus collects metrics, Grafana visualizes them.

YAML
YAML
JavaScript

Interview Tips for DevOps