Skip to content

dalevizo/ansible-rsync

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ansible-rsync

synchronize

An Ansible action plugin based rsync to make synchronizing a file paths in your playbooks quick and easy. Of course you could just use the command action to call rsync yourself, but you also have to add a fair number of boilerplate options and host facts. You still may need to. The synchronize action is meant to do common things with rsync easily. It does not provide access to the full power of rsync.

parameter required default choices comments
dest yes
    Path on the destination machine that will be synchronized from the source; The path can be absolute or relative.
    src yes
      Path on the source machine that will be synchronized to the destination; The path can be absolute or relative.
      verbosity no
        An integrater controling the amount of information returned during processing. The greater the value the more information rsync will report back. See the -v, --verbose option of the rsync man page for details. If verbosity is not defined or a value of 0 is assumed, the --quiet option is passed and information is supressed.
        mode no push
        • push
        • pull
        Specify the direction of the synchroniztion. In push mode the localhost or delgate is the source; In pull mode the inventory hostname in context is the source.
        delete no no
        • yes
        • no
        Delete files that don't exist (after transfer, not before) in src path.
        • Synchronization of src on the localhost to dest on the current inventory host
        synchronize: src=some/relative/path dest=/some/absolute/path
        
        • Synchronization of src path to dest path on the localhost
        local_action: synchronize src=some/relative/path dest=/some/absolute/path
        
        • Synchronization of src on the inventory host to the dest on the localhost.
        synchronize: mode=pull src=some/relative/path dest=/some/absolute/path
        
        • Synchronization of src on delegate to dest on the current inventory host
        synchronize: src=some/relative/path dest=/some/absolute/path
        
        • Synchronize and delete files in dest on inventory host not found in src of localhost.
        synchronize: src=some/relative/path dest=/some/absolute/path delete=yes
        
        • Synchronize and return verbose information from the rsync transfer.
        synchronize: src=some/relative/path dest=/some/absolute/path verbosity=1
        

        About

        An Ansible action plugin based on rsync to make synchronizing a file paths in your playbooks quick and easy.

        Resources

        Stars

        Watchers

        Forks

        Releases

        No releases published

        Packages

         
         
         

        Contributors