-
-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathmain.sh
More file actions
executable file
·43 lines (35 loc) · 951 Bytes
/
main.sh
File metadata and controls
executable file
·43 lines (35 loc) · 951 Bytes
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
#!/usr/bin/env bash
echo "Installing ZooKeeper Operator"
# tag::zk-op[]
stackablectl release install -i secret -i commons -i listener -i zookeeper 23.11
# end::zk-op[]
# tag::vector-helm-repo[]
helm repo add vector https://helm.vector.dev
helm repo update
# end::vector-helm-repo[]
# tag::vector-agg[]
helm install \
--wait \
--values vector-aggregator-values.yaml \
vector-aggregator vector/vector
# end::vector-agg[]
# tag::vector-discovery[]
kubectl apply -f vector-aggregator-discovery.yaml
# end::vector-discovery[]
# tag::zk[]
kubectl apply -f zookeeper.yaml
# end::zk[]
# Wait until the zookeeper-operator deployed the StatefulSet
kubectl wait \
--for=condition=available \
--timeout=5m \
zookeeperclusters.zookeeper.stackable.tech/simple-zk
# tag::grep[]
kubectl logs vector-aggregator-0 | grep "zookeeper.version=" | jq
# end::grep[]
if [ "${PIPESTATUS[1]}" -eq 0 ]
then
echo "it worked"
else
echo "it didn't work"
fi