2022-06-27 06:44:16 +00:00
|
|
|
# - name: Create folder structure(s)
|
|
|
|
# ansible.builtin.file:
|
|
|
|
# path: "{{ item }}"
|
|
|
|
# state: directory
|
|
|
|
# loop:
|
|
|
|
# - /foo
|
2022-06-24 21:44:10 +00:00
|
|
|
|
2022-06-24 22:50:44 +00:00
|
|
|
- name: Download & install static binaries
|
|
|
|
ansible.builtin.get_url:
|
|
|
|
url: "{{ item.url }}"
|
2022-06-25 06:33:12 +00:00
|
|
|
dest: /usr/local/bin/{{ item.filename }}
|
2022-06-24 22:50:44 +00:00
|
|
|
owner: root
|
|
|
|
group: root
|
|
|
|
mode: 0755
|
2022-06-25 16:44:43 +00:00
|
|
|
loop: "{{ dependencies.static_binaries | selectattr('archive', 'undefined') }}"
|
2022-06-26 15:54:19 +00:00
|
|
|
loop_control:
|
|
|
|
label: "{{ item.filename }}"
|
2022-06-25 16:44:43 +00:00
|
|
|
|
2022-06-25 21:32:29 +00:00
|
|
|
- name: Download, extract & install archived static binaries
|
|
|
|
include_tasks: dependencies.archive_compressed.yml
|
|
|
|
loop: "{{ dependencies.static_binaries | rejectattr('archive', 'undefined') | selectattr('archive', 'equalto', 'compressed') }}"
|
2022-06-25 21:57:55 +00:00
|
|
|
loop_control:
|
|
|
|
label: "{{ item.filename }}"
|
2022-06-24 22:50:44 +00:00
|
|
|
|
|
|
|
- name: Install ansible-galaxy collections
|
2022-06-24 21:44:10 +00:00
|
|
|
ansible.builtin.shell:
|
2022-06-25 06:33:12 +00:00
|
|
|
cmd: ansible-galaxy collection install {{ item }}
|
2022-06-24 21:44:10 +00:00
|
|
|
loop: "{{ dependencies.ansible_galaxy_collections }}"
|
2022-06-24 22:50:44 +00:00
|
|
|
|
2022-06-25 06:28:44 +00:00
|
|
|
- name: Install distro packages
|
|
|
|
ansible.builtin.apt:
|
2022-06-25 16:44:43 +00:00
|
|
|
pkg: "{{ dependencies.packages }}"
|
|
|
|
state: latest
|
2022-06-25 06:28:44 +00:00
|
|
|
update_cache: yes
|
|
|
|
install_recommends: no
|
|
|
|
|
2022-06-25 16:44:43 +00:00
|
|
|
- name: Upgrade all packages
|
2022-06-25 06:28:44 +00:00
|
|
|
ansible.builtin.apt:
|
2022-06-25 06:33:12 +00:00
|
|
|
name: '*'
|
2022-06-25 06:28:44 +00:00
|
|
|
state: latest
|
2022-06-25 16:44:43 +00:00
|
|
|
update_cache: yes
|
|
|
|
|
|
|
|
- name: Cleanup apt cache
|
|
|
|
ansible.builtin.apt:
|
|
|
|
autoremove: yes
|
|
|
|
purge: yes
|