main/postmarketos-base: enable zram-init service on upgrade (MR 4598)

The post-upgrade script in pmos-base isn't symlinked to the post-install
script, so zram-init wasn't being enabled on systems that upgraded to
the pmos-base version that intro'd this feature. I think this should
have been enabled by default on upgraded systems. There's a deviceinfo
toggle for it, so users who won't want to use this can set that var to
disable it, in that case having the service enabled is basically a
no-op.

Update by Oliver: add a comment to mention the deviceinfo variable

[ci:skip-build]: already built successfully in CI
This commit is contained in:
Clayton Craft 2023-12-05 09:40:32 -08:00 committed by Oliver Smith
parent f6467c52fe
commit dbd23fb13a
No known key found for this signature in database
GPG key ID: 5AE7F5513E0885CB
2 changed files with 4 additions and 1 deletions

View file

@ -1,6 +1,6 @@
pkgname=postmarketos-base
pkgver=29
pkgrel=0
pkgrel=1
pkgdesc="Meta package for minimal postmarketOS base"
url="https://postmarketos.org"
arch="noarch"

View file

@ -23,4 +23,7 @@ ln -sf "$localtime" /etc/localtime
rm -rf /etc/zoneinfo
[ "$restart" = "yes" ] && service -qq openrc-settingsd restart
# To turn zram-init into a no-op, set: deviceinfo_zram_swap_pct="0"
rc-update -q add zram-init default
exit 0