37 lines
782 B
YAML
37 lines
782 B
YAML
---
|
|
- name: Install dependencies
|
|
ansible.builtin.apt:
|
|
name: curl
|
|
|
|
- name: Install fetch script
|
|
ansible.builtin.template:
|
|
src: bambulab-fetch.sh
|
|
dest: /opt/bambulab-fetch.sh
|
|
owner: root
|
|
group: root
|
|
mode: 0755
|
|
|
|
- name: Install service
|
|
ansible.builtin.template:
|
|
src: bambulab-fetch.service
|
|
dest: /etc/systemd/system/bambulab-fetch.service
|
|
owner: root
|
|
group: root
|
|
mode: 0644
|
|
notify: daemon reload
|
|
|
|
- name: Install timer
|
|
ansible.builtin.template:
|
|
src: bambulab-fetch.timer
|
|
dest: /etc/systemd/system/bambulab-fetch.timer
|
|
owner: root
|
|
group: root
|
|
mode: 0644
|
|
notify: daemon reload
|
|
|
|
- name: Enable timer
|
|
ansible.builtin.systemd:
|
|
name: bambulab-fetch
|
|
state: started
|
|
enabled: yes
|
|
daemon_reload: true
|