Add tini for handling signals appropriately
This is a short-term workaround while we wait for upstream to implement proper handling of SIGTERM.
This commit is contained in:
parent
9374efb2bf
commit
bb91e64b56
|
|
@ -13,6 +13,12 @@ RUN curl -o /usr/local/bin/gosu -SL "https://github.com/tianon/gosu/releases/dow
|
||||||
&& rm /usr/local/bin/gosu.asc \
|
&& rm /usr/local/bin/gosu.asc \
|
||||||
&& chmod +x /usr/local/bin/gosu
|
&& chmod +x /usr/local/bin/gosu
|
||||||
|
|
||||||
|
# grab tini for signal processing and zombie killing
|
||||||
|
RUN set -x \
|
||||||
|
&& curl -fSL "https://github.com/krallin/tini/releases/download/v0.5.0/tini" -o /usr/local/bin/tini \
|
||||||
|
&& chmod +x /usr/local/bin/tini \
|
||||||
|
&& tini -h
|
||||||
|
|
||||||
# Add the officially endorsed Erlang debian repository:
|
# Add the officially endorsed Erlang debian repository:
|
||||||
# See:
|
# See:
|
||||||
# - http://www.erlang.org/download.html
|
# - http://www.erlang.org/download.html
|
||||||
|
|
|
||||||
|
|
@ -57,7 +57,7 @@ if [ "$1" = 'rabbitmq-server' ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
chown -R rabbitmq /var/lib/rabbitmq
|
chown -R rabbitmq /var/lib/rabbitmq
|
||||||
set -- gosu rabbitmq "$@"
|
set -- gosu rabbitmq tini -- "$@"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
exec "$@"
|
exec "$@"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue