2019-04-01 09:38:33 +00:00
|
|
|
---
|
2018-10-31 10:52:47 +00:00
|
|
|
- hosts: localhost
|
|
|
|
strategy: linear
|
|
|
|
vars:
|
|
|
|
mitogen_version: master
|
2019-05-02 21:24:21 +00:00
|
|
|
mitogen_url: https://github.com/dw/mitogen/archive/{{ mitogen_version }}.zip
|
2018-10-31 10:52:47 +00:00
|
|
|
tasks:
|
|
|
|
- name: Create mitogen plugin dir
|
|
|
|
file:
|
2019-05-02 21:24:21 +00:00
|
|
|
path: "{{ item }}"
|
2018-10-31 10:52:47 +00:00
|
|
|
state: directory
|
|
|
|
become: false
|
|
|
|
loop:
|
2019-05-02 21:24:21 +00:00
|
|
|
- "{{ playbook_dir }}/plugins/mitogen"
|
|
|
|
- "{{ playbook_dir }}/dist"
|
2018-10-31 10:52:47 +00:00
|
|
|
|
|
|
|
- name: download mitogen release
|
|
|
|
get_url:
|
2019-05-02 21:24:21 +00:00
|
|
|
url: "{{ mitogen_url }}"
|
|
|
|
dest: "{{ playbook_dir }}/dist/mitogen_{{ mitogen_version }}.zip"
|
2018-10-31 10:52:47 +00:00
|
|
|
validate_certs: true
|
|
|
|
|
|
|
|
- name: extract zip
|
|
|
|
unarchive:
|
2019-05-02 21:24:21 +00:00
|
|
|
src: "{{ playbook_dir }}/dist/mitogen_{{ mitogen_version }}.zip"
|
|
|
|
dest: "{{ playbook_dir }}/dist/"
|
2018-10-31 10:52:47 +00:00
|
|
|
|
|
|
|
- name: copy plugin
|
|
|
|
synchronize:
|
2019-05-02 21:24:21 +00:00
|
|
|
src: "{{ playbook_dir }}/dist/mitogen-{{ mitogen_version }}/"
|
|
|
|
dest: "{{ playbook_dir }}/plugins/mitogen"
|