server mode will start independent of configuration
Brought to you by:
mguessan
in the debian package of recent 5.0.0 build, there are files
/etc/default/davmail
/etc/init.d/davmail
with the first containing a variable to define if the start of the daemon should be enabled.
this file and the variable ENABLE_DAEMON is not respected by the init script.
therefore the server will start under all circumstances.
REMEDY:
suggest adding the following lines in head section:
DEFAULTS_FILE=/etc/default/davmail
# Fetch the defaults for operation
. $DEFAULTS_FILE
with a check in do_start() before daemon start:
# allowed start? (bool supported OK in sh):
$ENABLE_DAEMON || return 2
that should do it.
As I do not provide an init script in my deb package, I guess you are using official debian package...
=> please forward this issue directly to debian package maintainers at:
https://salsa.debian.org/debian/davmail/
The use of /etc/default/davmail is now discouraged in Debian and was actually removed. See https://lintian.debian.org/tags/init.d-script-should-always-start-service.html for more info.
The proper way to manage a service is:
$ update-rc.d davmail disable
$ update-rc.d davmail enable
or if using systemd
$ systemctl disable davmail
$ systemctl enable davmail
So this can be closed. Thanks for reporting!
Alex
Thanks, closing ticket