blob: a1f81586be40371bd4a77ea16adc2765cdb1b5c3 (
plain) (
blame)
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
|
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: replicated-partitions
namespace: test-kafka
spec:
replicas: 1
selector:
matchLabels:
test-type: readiness
test-target: under-replicated-partitions
template:
metadata:
labels:
test-type: readiness
test-target: under-replicated-partitions
spec:
containers:
- name: kafka
image: solsson/kafka:1.0.0@sha256:17fdf1637426f45c93c65826670542e36b9f3394ede1cb61885c6a4befa8f72d
command:
- /bin/bash
- -ec
- >
touch /tmp/testlog;
tail -f /tmp/testlog
readinessProbe:
exec:
command:
- /bin/bash
- -c
- >
echo "### $(date -Ins -u) ###" >> /tmp/testlog
&&
[
$(
./bin/kafka-topics.sh
--zookeeper zookeeper.kafka:2181
--describe
--under-replicated-partitions
|
tee -a /tmp/testlog
|
wc -l
)
-eq
0
]
periodSeconds: 30
timeoutSeconds: 29
|