This commit is contained in:
Mihai Galos 2023-11-21 01:47:07 -08:00 committed by GitHub
commit 8534416a35
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 48 additions and 0 deletions

27
nginx/deployment.yaml Normal file
View File

@ -0,0 +1,27 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: my-nginx
namespace: nginx
spec:
selector:
matchLabels:
run: my-nginx
replicas: 1
template:
metadata:
labels:
run: my-nginx
spec:
containers:
- image: nginx
name: my-nginx
resources:
requests:
memory: "128Mi"
cpu: "250m"
limits:
memory: "128Mi"
ports:
- containerPort: 443
- containerPort: 80

21
nginx/service.yaml Normal file
View File

@ -0,0 +1,21 @@
apiVersion: v1
kind: Service
metadata:
name: my-nginx
namespace: nginx
labels:
run: my-nginx
spec:
type: NodePort
ports:
- port: 8081
targetPort: 80
nodePort: 31704
protocol: TCP
name: http
- port: 443
nodePort: 32453
protocol: TCP
name: https
selector:
run: my-nginx