| --- |
| # tasks file for apigee-opdk-setup-local-repository-archive |
| - name: Clean up and repos in /tmp |
| file: |
| path: '{{ archive_folder }}/repos' |
| state: absent |
| #- block: |
| # - name: Unarchive local archive to remote nodes |
| # unarchive: |
| # src: '{{ local_resource_path }}/{{ archive_name }}' |
| # dest: '{{ archive_folder }}' |
| # copy: '{{ copy_archive }}' |
| # |
| # rescue: |
| - name: Install rsync if its missing |
| yum: |
| name: rsync |
| state: present |
| |
| - name: Use rsync to copy to remote node |
| synchronize: |
| src: "{{ local_resource_path }}/{{ archive_name }}" |
| dest: "{{ archive_folder }}/{{ archive_name }}" |
| |
| - name: Unarchive local archive to remote nodes |
| unarchive: |
| src: '{{ archive_folder }}/{{ archive_name }}' |
| dest: '{{ archive_folder }}' |
| copy: false |
| |
| |