mirror of
https://github.com/MichaelCade/90DaysOfDevOps.git
synced 2025-07-28 13:50:59 +07:00
fix .git file in Kubernetes
This commit is contained in:
41
Days/Kubernetes/nginx-stateless-demo.yaml
Normal file
41
Days/Kubernetes/nginx-stateless-demo.yaml
Normal file
@ -0,0 +1,41 @@
|
||||
apiVersion: v1
|
||||
kind: Namespace
|
||||
metadata:
|
||||
name: nginx
|
||||
"labels": {
|
||||
"name": "nginx"
|
||||
}
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: nginx-deployment
|
||||
namespace: nginx
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: nginx
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: nginx
|
||||
spec:
|
||||
containers:
|
||||
- name: nginx
|
||||
image: nginx
|
||||
ports:
|
||||
- containerPort: 80
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: nginx-service
|
||||
namespace: nginx
|
||||
spec:
|
||||
selector:
|
||||
app: nginx-deployment
|
||||
ports:
|
||||
- protocol: TCP
|
||||
port: 80
|
||||
targetPort: 80
|
Reference in New Issue
Block a user