Project

General

Profile

Actions

Bug #22391

open

Standardize systemd service handling

Added by Brett Smith 10 days ago.

Status:
New
Priority:
Normal
Assigned To:
-
Category:
Deployment
Target version:
-
Story points:
-

Description

At the bottom of source:build/go-python-package-scripts/postinst.sh, we automatically enable and start any included service. This is not great for a couple of reasons:

  • If an administrator previously disabled a service, any package upgrade will re-enable it. (They can work around this by masking the unit, but it's still rude.)
  • RPM packages are never supposed to do this by policy, so it's surprising behavior for those administrators.

IMO our packages should never automatically enable a service, and instead we should leave that job to a Salt/Ansible installer, which has more information about what the state of the system is expected to be than a postinst script ever can. If we install service definitions directly to /lib/systemd/system from our fpm build, then the main body of our generic postinst can be as simple as:

if [ -d /run/systemd/system ]; then
  systemctl daemon-reload
  systemctl try-restart SERVICE
fi

Related issues 1 (0 open1 closed)

Related to Arvados - Bug #22349: RHEL8 Appstream Ruby not useable on 3.0ResolvedActions
Actions #1

Updated by Brett Smith 10 days ago

  • Related to Bug #22349: RHEL8 Appstream Ruby not useable on 3.0 added
Actions

Also available in: Atom PDF