Skip to main content
InterviewHubPRO
Section Overview
Q31

Question 31 of 50

Part 3: Kubernetes Infrastructure as Code & GitOps (31 - 42)

62%
Terraform & IaC (50 Qs)•Part 3: Kubernetes Infrastructure as Code & GitOps (31 - 42)

What is the Kubernetes Operator Pattern and Custom Resource Definitions (CRDs)?

senior LevelMost AskedKubernetes

In Simple Words: An Operator encodes human operational domain knowledge (backup, failover, scaling) into software:

  1. CRD (Custom Resource Definition): Extends Kubernetes API with new resource types (e.g. apiVersion: postgres-operator/v1, kind: PostgresCluster).
  2. Custom Controller: Runs a continuous Reconciliation Loop: Actual State -> Desired State. If a database replica fails, the operator provisions a new one and triggers replication catch-up automatically.