add update tag system

This commit is contained in:
Pim Kunis 2023-02-20 21:49:55 +01:00
parent 4a3995ba29
commit bc237e82af
6 changed files with 13 additions and 6 deletions
roles/virtualbox/tasks

View file

@ -3,16 +3,19 @@
get_url:
url: https://www.virtualbox.org/download/oracle_vbox_2016.asc
dest: /etc/apt/trusted.gpg.d/oracle_vbox_2016.asc
tags: update
- name: Install VirtualBox APT repository
become: true
apt_repository:
repo: "deb [arch=amd64 signed-by=/etc/apt/trusted.gpg.d/oracle_vbox_2016.asc] https://download.virtualbox.org/virtualbox/debian {{ ansible_distribution_release }} contrib"
register: apt_repository
tags: update
- name: Update APT cache
become: true
apt:
update_cache: true
when: apt_repository.changed
tags: update
- name: Install VirtualBox
become: true
apt: