diff --git a/group_vars/fileserver.yml b/group_vars/fileserver.yml index db37f11b..7eba43c8 100644 --- a/group_vars/fileserver.yml +++ b/group_vars/fileserver.yml @@ -70,3 +70,8 @@ password: "{{ lookup('keepass', 'fileserver_smb_user_brother_ads2700w', 'password') }}" - name: 'photoprism' password: "{{ lookup('keepass', 'fileserver_smb_user_photoprism', 'password') }}" + + ### mgrote.apt_manage_packages + apt_packages_internet: + - https://github.com/rclone/rclone/releases/download/v1.59.2/rclone-v1.59.2-linux-amd64.deb + - http://docker10.grote.lan:3344/bash-helper-scripts-mgrote/bash-helper-scripts-mgrote-latest.deb diff --git a/roles/mgrote.rclone/tasks/main.yml b/roles/mgrote.rclone/tasks/main.yml index e2bbfdde..94f69a38 100644 --- a/roles/mgrote.rclone/tasks/main.yml +++ b/roles/mgrote.rclone/tasks/main.yml @@ -1,10 +1,14 @@ --- - - name: install packages - become: true - ansible.builtin.apt: - name: - - rclone - state: present + - name: Check if rclone is installed + command: which rclone + changed_when: false + failed_when: rclone_installed.rc not in [0,1] + register: rclone_installed + + - name: Install rclone first! + fail: + msg: "rclone is not installed, install it first" + when: rclone_installed.rc not in [ 0 ] - name: Create rclone Directory become: true