Bug 33396 - FR: file triggers
Summary: FR: file triggers
Status: NEW
Alias: None
Product: Sisyphus
Classification: Development
Component: puppet (show other bugs)
Version: unstable
Hardware: all Linux
: P3 enhancement
Assignee: majioa@altlinux.org
QA Contact: qa-sisyphus
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-04-19 20:09 MSK by Ivan Zakharyaschev
Modified: 2022-09-22 22:44 MSK (History)
11 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ivan Zakharyaschev 2017-04-19 20:09:55 MSK
puppet agent could invoke special file triggers when important files are modified.

For example, I've described one case like this in a manifest:

    file {
      "/etc/resolv.conf":
        ensure  => present,
        content => template('apipkg/dnsmasq/resolv.conf.erb'),
        notify => Exec['update_chrooted']
    }
    exec { 'update_chrooted':
      command     => 'update_chrooted all',
      refreshonly => true,
    }

puppet agent could have had built-in triggers for such files. Perhaps, invoking the triggers from /usr/lib/rpm/*.filetrigger would also make sense.

The tricky thing is to do this not very often and not very late: after a group of files is modified, but before any other action (so that there is no attempt to use the modified files).
Comment 1 Малъ Скрылевъ 2022-09-22 22:44:55 MSK
А можно ли на примере продемонстрировать функциональность?