eb2bd80851
systemd supports a watchdog (via the WatchdogSec service file option) which will send the program a SIGABRT when the timer expires, however currently this causes offlineimap to be killed immediately. This patch registers SIGABRT and handles it in the same manner as SIGUSR2, so that the current synchronisation is completed before the program exits safely. This makes offlineimap more flexible and robust for persistent setups that make use of holdconnectionopen and autorefresh options. For example, it may be useful in assisting with the occasional situation where offlineimap may not return successfully after a suspend and resume. To make use of this, users could add the following to the [Service] section of their systemd offlineimap service file (restart every 5 minutes): Restart=on-watchdog WatchdogSec=300 Signed-off-by: Chris Smart <mail@csmart.io> Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net> |
||
---|---|---|
.. | ||
folder | ||
repository | ||
ui | ||
utils | ||
__init__.py | ||
accounts.py | ||
bundled_imaplib2.py | ||
CustomConfig.py | ||
emailutil.py | ||
error.py | ||
globals.py | ||
imaplibutil.py | ||
imapserver.py | ||
imaputil.py | ||
init.py | ||
localeval.py | ||
mbnames.py | ||
threadutil.py | ||
virtual_imaplib2.py |