diff --git a/rabbitmq/Chart.yaml b/rabbitmq/Chart.yaml index 36cd0e443..a2261232f 100644 --- a/rabbitmq/Chart.yaml +++ b/rabbitmq/Chart.yaml @@ -15,6 +15,6 @@ apiVersion: v1 appVersion: v3.7.26 description: OpenStack-Helm RabbitMQ name: rabbitmq -version: 0.1.15 +version: 0.1.16 home: https://github.com/rabbitmq/rabbitmq-server ... diff --git a/rabbitmq/templates/bin/_rabbitmq-start.sh.tpl b/rabbitmq/templates/bin/_rabbitmq-start.sh.tpl index 794f09199..4ef849fd1 100644 --- a/rabbitmq/templates/bin/_rabbitmq-start.sh.tpl +++ b/rabbitmq/templates/bin/_rabbitmq-start.sh.tpl @@ -94,4 +94,7 @@ if ! [ "${POD_INCREMENT}" -eq "0" ] && ! [ -d "/var/lib/rabbitmq/mnesia" ] ; the rm -fv /tmp/rabbit-disable-readiness /tmp/rabbit-disable-liveness-probe fi +{{- if .Values.forceBoot.enabled }} +if [ "${POD_INCREMENT}" -eq "0" ] && [ -d "/var/lib/rabbitmq/mnesia/${RABBITMQ_NODENAME}" ]; then rabbitmqctl force_boot; fi +{{- end}} exec rabbitmq-server diff --git a/rabbitmq/values.yaml b/rabbitmq/values.yaml index c593966f5..8eb51c649 100644 --- a/rabbitmq/values.yaml +++ b/rabbitmq/values.yaml @@ -46,6 +46,12 @@ images: - dep_check - image_repo_sync +# forceBoot: executes 'rabbitmqctl force_boot' to force boot on +# cluster shut down unexpectedly in an unknown order. +# ref: https://www.rabbitmq.com/rabbitmqctl.8.html#force_boot +forceBoot: + enabled: false + pod: probes: prometheus_rabbitmq_exporter: diff --git a/releasenotes/notes/rabbitmq.yaml b/releasenotes/notes/rabbitmq.yaml index 4ec33690a..bce748d17 100644 --- a/releasenotes/notes/rabbitmq.yaml +++ b/releasenotes/notes/rabbitmq.yaml @@ -15,4 +15,5 @@ rabbitmq: - 0.1.13 Add prestop action and version 3.8.x upgrade prep - 0.1.14 Update readiness and liveness probes - 0.1.15 Update htk requirements + - 0.1.16 Add force_boot command to rabbit start template ...