Skip to content

Instantly share code, notes, and snippets.

@yoavsal
Created July 12, 2020 08:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yoavsal/4ee8ea96b2557d4645ee923858e28bb5 to your computer and use it in GitHub Desktop.
Save yoavsal/4ee8ea96b2557d4645ee923858e28bb5 to your computer and use it in GitHub Desktop.
$ kubectl describe cm zeebe-zeebe
Name: zeebe-zeebe
Namespace: default
Labels: app=zeebe-zeebe
app.kubernetes.io/instance=zeebe
app.kubernetes.io/name=zeebe-cluster
Annotations: <none>
Data
====
startup.sh:
----
#!/usr/bin/env bash
set -eux -o pipefail
export ZEEBE_BROKER_NETWORK_ADVERTISEDHOST=${ZEEBE_BROKER_NETWORK_ADVERTISEDHOST:-$(hostname -f)}
export ZEEBE_BROKER_CLUSTER_NODEID=${ZEEBE_BROKER_CLUSTER_NODEID:-${K8S_POD_NAME##*-}}
# As the number of replicas or the DNS is not obtainable from the downward API yet,
# defined them here based on conventions
export ZEEBE_BROKER_CLUSTER_CLUSTERSIZE=${ZEEBE_BROKER_CLUSTER_CLUSTERSIZE:-1}
contactPointPrefix=${K8S_POD_NAME%-*}
contactPoints=${ZEEBE_BROKER_CLUSTER_INITIALCONTACTPOINTS:-""}
if [[ -z "${contactPoints}" ]]; then
for ((i=0; i<${ZEEBE_BROKER_CLUSTER_CLUSTERSIZE}; i++))
do
contactPoints="${contactPoints},${contactPointPrefix}-$i.$(hostname -d):26502"
done
export ZEEBE_BROKER_CLUSTER_INITIALCONTACTPOINTS="${contactPoints}"
fi
if [ "$(ls -A /exporters/)" ]; then
mkdir /usr/local/zeebe/exporters/
cp -a /exporters/*.jar /usr/local/zeebe/exporters/
else
echo "No exporters available."
fi
exec /usr/local/zeebe/bin/broker
application.yaml:
----
Events: <none>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment