23 lines
713 B
YAML
23 lines
713 B
YAML
- name: Check if autorestic is installed
|
|
ansible.builtin.stat:
|
|
path: /usr/local/bin/autorestic
|
|
register: software_autorestic_status
|
|
|
|
- name: Install autorestic
|
|
ansible.builtin.shell:
|
|
executable: /usr/bin/bash
|
|
cmd: set -o pipefail && wget -qO - https://raw.githubusercontent.com/cupcakearmy/autorestic/master/install.sh | bash
|
|
when: not software_autorestic_status.stat.exists
|
|
changed_when: true
|
|
become: true
|
|
|
|
- name: Check if restic is installed
|
|
ansible.builtin.stat:
|
|
path: /usr/local/bin/restic
|
|
register: software_restic_status
|
|
|
|
- name: Install restic
|
|
ansible.builtin.command: autorestic install
|
|
when: not software_restic_status.stat.exists
|
|
changed_when: true
|
|
become: true
|