core-deployments/test-ingress.yaml
2022-09-08 02:24:36 +02:00

52 lines
No EOL
898 B
YAML

---
apiVersion: apps/v1
kind: Deployment
metadata:
name: helloworld-deployment
labels:
app: helloworld
spec:
replicas: 3
selector:
matchLabels:
app: helloworld
template:
metadata:
labels:
app: helloworld
spec:
containers:
- name: helloworld
image: testcontainers/helloworld
ports:
- containerPort: 8080
---
apiVersion: v1
kind: Service
metadata:
name: helloworld-service
spec:
selector:
app: helloworld
ports:
- protocol: TCP
port: 80
targetPort: 8080
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: helloworld-ingress
spec:
ingressClassName: nginx
rules:
- host: "lb1.yolokube.de"
http:
paths:
- pathType: Prefix
path: "/"
backend:
service:
name: helloworld-service
port:
number: 80