Junior — Middle
Have you created direct manifests for deploying objects in Kubernetes?
sobes.tech AI
Answer from AI
Yes, direct manifests for deploying objects in Kubernetes are YAML files that describe the necessary resources (Pod, Deployment, Service, etc.).
Example of a simple Deployment manifest:
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deployment
spec:
replicas: 3
selector:
matchLabels:
app: nginx
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:1.14.2
ports:
- containerPort: 80
This manifest can be applied with the command:
kubectl apply -f deployment.yaml
Creating and editing such manifests is standard practice for managing infrastructure in Kubernetes.