AZ
Definition
AZ typically refers to “Availability Zone” in cloud computing environments. An Availability Zone is a distinct location within a cloud provider’s region, designed to be isolated from failures in other zones. Each zone has its own power, cooling, and networking infrastructure, allowing for high availability and fault tolerance by distributing resources across multiple zones.
Secure Settings Example
# Example of a secure configuration for deploying a service across multiple AZs in Kubernetes
apiVersion: apps/v1
kind: Deployment
metadata:
name: my-secure-app
spec:
replicas: 3
template:
spec:
containers:
- name: my-container
image: my-secure-app:latest
affinity:
podAntiAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
- labelSelector:
matchExpressions:
- key: app
operator: In
values:
- my-secure-app
topologyKey: "topology.kubernetes.io/zone"
Insecure Settings Example
# Example of an insecure configuration that does not utilize multiple AZs
apiVersion: apps/v1
kind: Deployment
metadata:
name: my-insecure-app
spec:
replicas: 3
template:
spec:
containers:
- name: my-container
image: my-insecure-app:latest
# Missing affinity settings, risking all pods being scheduled in a single AZ