Package: rabbitmq-server
Version: 3.7.8-4
Severity: important

Dear Maintainer,

The debian/rabbitmq-server.service file injects a wrapper shell script
that does funky things rather than directly starting the actual rabbitmq
service. Apart from deviating from convertional systemd behaviour it
also breaks several documented ways to configure the service provided by
the upstream documentation. (I consider this extremely user hostile
behaviour!)

As a general plea please stop injecting shell scripts everywhere!

As a more specific example I'd suggest you might want to look at
eg. the logging chapter and 
https://www.rabbitmq.com/logging.html#logging-to-console
This is just one example of what your shell wrapper hack breaks.

As a service to others who might find this useful, I've found the
easiest way to unbreak logging (to the journal) to be overriding
rabbitmq-server.service (systemctl edit rabbitmq-server.service) with:

[Service]
Environment=LOGS=-
ExecStart=
ExecStart=/usr/lib/rabbitmq/bin/rabbitmq-server

This skips over one layer of shell script indirections which is the one
responsible for breaking the standard output logging (and goes straight
for the next level of shell script indirection before starting the
actual service). It's not clear what the purpose of the
/usr/sbin/rabbitmq-server script is as all it seems to do is break
upstreams documented logging configuration options, but in a systemd
environment this script should be completely superfluous so only
benefits from skipping over.

Regards,
Andreas Henriksson

PS. sd_notify bindings for erlang can be found at
https://github.com/systemd/erlang-sd_notify which will help you avoid
hackish shell scripting.

Reply via email to