'Twas brillig, and Olivier Blin at 25/11/12 23:31 did gyre and gimble: > Colin Guthrie <[email protected]> writes: > >> 'Twas brillig, and Olivier Blin at 25/11/12 15:19 did gyre and gimble: >>> Colin Guthrie <[email protected]> writes: >>> >>>> 1. "systemd-tmpfiles --create" is not run in the %post (before >>>> add-service helper) (note that on cauldron the command must be: >>>> "systemd-tmpfiles --create openvpn.conf"). This means that you'll need a >>>> reboot before openvpn will work on mga2 after installing it. >>> >>> Hi, >>> >>> Shouldn't this be done through a rpm filetrigger? >> >> I don't think there is a way to specify which files triggered the file >> trigger is there? >> >> Basically we'd need to know the basename of the file that changed, also >> there are times when it has to be excluded (e.g. some files should not >> be run except at boot). > > Looks like this list is available to the script from stdin, see > /var/lib/rpm/filetriggers/httpd.script or > /var/lib/rpm/filetriggers/pear.script
OK good to know. Sadly the ordering is still wrong as this needs to be run after %pre but before any calls to %_post_service (i.e. in %post). As a result I don't think it's really possible to automate this. It could be added to a filetrigger for "safety" and baked into %_post_service but it still doesn't cover several corner cases, and I don't think it's really worth the bother personally. Col -- Colin Guthrie colin(at)mageia.org http://colin.guthr.ie/ Day Job: Tribalogic Limited http://www.tribalogic.net/ Open Source: Mageia Contributor http://www.mageia.org/ PulseAudio Hacker http://www.pulseaudio.org/ Trac Hacker http://trac.edgewall.org/
