apk autoupdate on alpine linux
β’ 114 words β’ 1 min β’ updated
β οΈ This post is over one year old. It may no longer be up to date or relevant. Opinions may have changed.
Problem statement: Upon running doas apk upgrade on Alpine Linux, select
packages with binaries backed by system services should be automatically
restarted.
Deb-based systems have
checkrestart(8).
On Alpine, the best available approach as of today is https://github.com/jirutka/apk-autoupdate/:
shell
doas apk add apk-autoupdate
$EDITOR /etc/apk/autoupdate.confThen make the two following changes1:
# Because the default is '*', which will prevent all services from restarting.
services_blacklist=""
# List of services that should be restarted upon package upgrades.
services_whitelist="miniflux tailscale"From this point on, whenever there are system upgrades for the aforementioned
services (doas apk upgrade), they will be automatically restarted. There’s no
need for doas /etc/init.d/miniflux restart.
-
h/t to @fossdd for replying to my https://github.com/jirutka/apk-autoupdate/issues/8 thread. ↩︎