On Tue, Jul 19, 2005 at 02:10:18PM -0500, Evan Harris wrote: > I looked in the patches directory, and see there is already a > pre-post-exec.diff patch to allow for running scripts before and after > the chroot, but I'm more interested in running after successful rsync > completion than after the chroot.
That patch does run a command after the completion of the rsync (whether it was successful or not). I've just upgraded it to add more environment variables (such as module name, module path, host name, host IP, user name, exit status). I also changed where the post-rsync exec happens so that both the pre- and post-xfer are both now run by the user that runs the daemon (not the module's user) and without any chroot constraints (the old patch was simpler, and it made the post-xfer command run in a more restricted setting than the pre-xfer command). You can see the latest patch here: http://rsync.samba.org/ftp/unpacked/rsync/patches/pre-post-exec.diff > Maybe also a way to bypass the script if no files were transferred, > but the rsync was otherwise error-free. The current patch doesn't include any info on transfer direction nor any transfer stats (which might not be easy to do). ..wayne.. -- To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html