Menu

#692 server mode will start independent of configuration

v5.0.0
closed
nobody
5
2019-01-09
2018-11-28
Qu Bit
No

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.

Discussion

  • Mickael Guessant

    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/

     
  • niol

    niol - 2018-12-28

    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

     
  • Mickael Guessant

    • status: open --> closed
     
  • Mickael Guessant

    Thanks, closing ticket

     

Log in to post a comment.

MongoDB Logo MongoDB