On Fri, 2017-01-20 at 12:02 +0100, Jordi Massaguer Pla wrote:
Hi packagers,
I am packaging docker and we have this problem that if a user runs an unattended update, docker gets updated and so restarted. However, this is causing downtime issues on their services which are inside containers.
I know there is the "--skip-interactive" flag for zypper ...
So my question is. Should we mark docker as "interactive" and if so, how do we do that?
That's not the right approach
Should we not restart docker when installing? I think you should, but am I wrong?
There is a config flag in /etc/susconfig that gives users control over if they normally want their services restarted on update (which is the default and we should keep doing for all services that do not 'break the update sequence') See /etc/sysconfig/services: DISABLE_RESTART_ON_UPDATE= and DISABLE_STOP_ON_REMOVAL= Packages that KNOW that they case very negative effects on restart (e.g. dbus, the X server, PackageKit) can export this variable in their post script just before executing the service handling macros. But for docker, where the issue is 'only' downtime, I'd argue it is up to the admin to decide if he wants to skip the restart (by setting the corresponding variables in his system) - and thus take care of actually enabling the new services, or not (follow the default, restart the service up update)
Are there other packages with similar problems? mariadb?
The 'rule' is basically: if the service can be restarted without impacting the update session, it should be done. Known exceptions so far are: * PackageKit: users updating with any PK-related tool would result in an interrupted system update - hence PK must not be restarted * xdm: a restart of the display-manager terminates running X-sessions of a user. This clearly impacts the running update process if not done in a screen/tmux session (or on a text console) * dbus-1: just seen last week: restarting dbus makes pretty much all running dbus-sessions disapear. with X running on systemd-logind nowadays, this is a bad idea. Cheers, Dominique