一、Pod定义
1、Pod定义详解
YAML格式:
apiVersion: apps/v1
kind: Deployment
metadata:
name: string
namespace: string
labels:
app: string
annotations:
- name: string
spec:
containers:
- name: string
- image: nginx:1.15.2
imagePullPolicy: [Always | Never | IfNotPresent]
command: [string]
args: [string]
workingDir: string
volumeMounts:
- name: string
mountPath: string
readOnly: boolean
ports:
- name: string
containerPort: int
hostPort: int
protocol: string
env:
- name: string
value: string
resources:
limits:
cpu: string
memory: string
requests:
cpu: string
memory: string
livenessProbe:
exec:
command: [string]
httpGet:
path: string
port: number
host: string
scheme: string
httpHeaders: