-
Notifications
You must be signed in to change notification settings - Fork 0
/
redpanda-test.yaml
124 lines (124 loc) · 2.72 KB
/
redpanda-test.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: consumer
spec:
replicas: 1
selector:
matchLabels:
app: consumer
template:
metadata:
labels:
app: consumer
spec:
containers:
- name: consumer
image: ghcr.io/forumviriumhelsinki/k8s-redpanda-test-consumer:latest
ports:
- containerPort: 8000
---
apiVersion: v1
kind: Service
metadata:
name: consumer
spec:
ports:
- name: http
port: 80
targetPort: 8000
selector:
app: consumer
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: consumer
namespace: redpanda-test
annotations:
cert-manager.io/cluster-issuer: "letsencrypt-prod"
# nginx.ingress.kubernetes.io/ssl-passthrough: "true"
# If you encounter a redirect loop or are getting a 307 response code
# then you need to force the nginx ingress to connect to the backend using HTTPS.
#
# nginx.ingress.kubernetes.io/backend-protocol: "HTTPS"
spec:
ingressClassName: nginx
tls:
- hosts:
- consumer.redpanda-test.dataportal.fi
secretName: consumer-redpanda-test-server-tls
rules:
- host: consumer.redpanda-test.dataportal.fi
http:
paths:
- pathType: Prefix
path: /
backend:
service:
name: consumer
port:
name: http
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: producer
spec:
replicas: 1
selector:
matchLabels:
app: producer
template:
metadata:
labels:
app: producer
spec:
containers:
- name: producer
image: ghcr.io/forumviriumhelsinki/k8s-redpanda-test-producer:latest
ports:
- containerPort: 8000
---
apiVersion: v1
kind: Service
metadata:
name: producer
spec:
ports:
- name: http
port: 80
targetPort: 8000
selector:
app: producer
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: producer
namespace: redpanda-test
annotations:
cert-manager.io/cluster-issuer: "letsencrypt-prod"
# nginx.ingress.kubernetes.io/ssl-passthrough: "true"
# If you encounter a redirect loop or are getting a 307 response code
# then you need to force the nginx ingress to connect to the backend using HTTPS.
#
# nginx.ingress.kubernetes.io/backend-protocol: "HTTPS"
spec:
ingressClassName: nginx
tls:
- hosts:
- producer.redpanda-test.dataportal.fi
secretName: producer-redpanda-test-server-tls
rules:
- host: producer.redpanda-test.dataportal.fi
http:
paths:
- pathType: Prefix
path: /
backend:
service:
name: producer
port:
name: http