nginx deployment

This commit is contained in:
Thilo Behnke
2022-08-10 17:41:35 +02:00
parent 96f3299c45
commit af52430efd

47
k8s-deployment.yml Normal file
View File

@@ -0,0 +1,47 @@
---
apiVersion: v1
kind: Service
metadata:
name: nginx-service
spec:
selector:
wasm.pong.io/name: nginx
type: LoadBalancer
ports:
- name: nginx-port
protocol: TCP
port: 80
targetPort: http-svc
- name: nginx-sec-port
protocol: TCP
port: 443
targetPort: https-svc
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deployment
labels:
wasm.pong.io/name: nginx
spec:
replicas: 3
selector:
matchLabels:
wasm.pong.io/name: nginx
template:
metadata:
name: nginx
labels:
wasm.pong.io/name: nginx
spec:
containers:
- name: client
image: docker-registry:443/wasm-pong/nginx
env:
- name: API_SERVER
value: pong-server-service
ports:
- containerPort: 80
name: http-svc
- containerPort: 443
name: https-svc