1
0
mirror of https://github.com/altlinux/gpupdate.git synced 2025-03-21 18:50:38 +03:00

Postinst trigger introduced

There are situations when we might lose storage compatibility between
versions due to SQLite3 table structure changes. This commit introduces
trigger which removes old storage in case of specific version change.

The storage will be regenerated on next GPOA run.
This commit is contained in:
Игорь Чудов 2020-08-21 16:21:15 +04:00
parent 43b1ea392f
commit 37416ab77d
Signed by untrusted user: nir
GPG Key ID: 0F3883600CAE7AAC

View File

@ -76,6 +76,11 @@ install -Dm0644 doc/gpupdate.1 %buildroot/%_man1dir/gpupdate.1
%post
%post_service gpupdate
# Remove storage in case we've lost compatibility between versions.
# The storage will be regenerated on GPOA start.
%triggerpostun -- %name > 0.7
rm -f %_cachedir/%name/registry.sqlite
%files
%_sbindir/gpoa
%_sbindir/gpupdate-setup