homeserver/roles/mgrote.install_packages/tasks/main.yml
mg d40efd2fb7 Rolle: install_packages: Variable extra_programs (#8)
Syntax korrigiert - 2

Syntax korrigiert

Fange leere Variable ab

Abhängigkeit restic mit reingenommen

Jenkins extra Programms als Var

install_packages mit extra-programs Var ausgestattet

Co-authored-by: Michael Grote <38253905+quotengrote@users.noreply.github.com>
Reviewed-on: mg/ansible#8
2020-12-22 13:20:29 +01:00

48 lines
1.2 KiB
YAML

- name: apt update
become: yes
ansible.builtin.apt:
update_cache: yes
cache_valid_time: 300
- name: install common-packages
become: yes
ansible.builtin.apt:
name: "{{ programs_common }}"
state: present
- name: install extra-packages
become: yes
ansible.builtin.apt:
name: "{{ programs_extra }}"
state: present
when: programs_extra is defined
- name: install vm-packages
become: yes
ansible.builtin.apt:
name: "{{ programs_only_vms }}"
state: present
when: ansible_virtualization_role == 'guest'
- name: install physical-packages
become: yes
ansible.builtin.apt:
name: "{{ programs_only_physical }}"
state: present
when: ansible_virtualization_role != 'guest'
- name: copy hddtemps.sh
become: yes
ansible.builtin.template:
src: "hddtemps.sh"
dest: "/usr/local/bin/hddtemps.sh"
mode: a+x
when: ansible_virtualization_role != 'guest'
- name: copy systemtemps.sh
become: yes
ansible.builtin.template:
src: "systemtemps.sh"
dest: "/usr/local/bin/systemtemps.sh"
mode: a+x
when: ansible_virtualization_role != 'guest'