Uncompress module for ansible. Lets you download an uncompress .gz and .bz2 files which currently isn't possible with the unarchive built-in module. https://galaxy.ansible.com/compscidr/uncompress
Motivated by the push-back against .gz .bz2 not being supported for compressed files: ansible/ansible-modules-core#3241 (comment)
and the existance of this project: https://github.com/vadikgo/uncompress.
Updating the existing project to support installation via a meta/requirements.yml
file and then submitting to ansible galaxy so that it can be found and installed
easily.
ansible-galaxy install compscidr.uncompress
Add the following to requirements.yml
roles:
- name: compscidr.uncompress
Then run
ansible-galaxy install -r requirements.yml
Add the following to your requirements.yml
file:
# from github
- src: https://github.com/compscidr/ansible-uncompress
name: compscidr.uncompress
Then run
ansible-galaxy install -r requirements.yml
---
- name: Install some gz file:
hosts: all
roles:
- compscidr.uncompress
tasks:
- name: install cheat # https://github.com/cheat/cheat/blob/master/INSTALLING.md
tags: cheat
become: true
uncompress:
copy: no
src: https://github.com/cheat/cheat/releases/download/4.3.1/cheat-linux-amd64.gz
dest: /usr/local/bin/cheat
mode: '755'