Kubernetes Objects: Pods
Pods are (an abstraction of containers):
- the smallest deployable units of computing
- group of one or more containers (tightly coupled)
- could be replicated (scaled horizontally)
- ephemeral, disposable entities (The Pod remains on the node until the Pod finishes execution, the Pod object is deleted, the Pod is evicted for lack of resources, or the node fails.)
Example of .yaml (or .yml) file:
apiVersion: v1
kind: Pod
metadata:
name: redis
spec:
containers:
- name: redis
image: redis
volumeMounts:
- name: redis-storage
mountPath: /data/redis
volumes:
- name: redis-storage
emptyDir: {}