Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- apiVersion: apps/v1
- kind: Deployment
- metadata:
- name: <your-name>-deployment
- spec:
- selector:
- matchLabels:
- app: <your-name>-app
- replicas: 2 # tells deployment to run 2 pods matching the template
- template:
- metadata:
- labels:
- app: <your-name>-app
- spec:
- containers:
- - name: <your-name>-container
- image: nginx:latest
- ports:
- - containerPort: 80
- ---
- apiVersion: v1
- kind: Service
- metadata:
- name: <your-name>-service
- labels:
- app: <your-name>-app
- spec:
- ports:
- - port: 80
- selector:
- app: <your-name>-app
- type: ClusterIP
Add Comment
Please, Sign In to add comment