Skip to content
Snippets Groups Projects
Commit 3bfd2d08 authored by istmxrein's avatar istmxrein
Browse files

add role for apt update

parent 12f69d33
No related branches found
No related tags found
No related merge requests found
---
- name: Update all packages
apt:
upgrade: full
update_cache: yes
register: update
when: ansible_distribution == 'Debian' or ansible_distribution == 'Ubuntu'
- name: Remove dependencies that are no longer required
apt:
autoremove: yes
when: ansible_distribution == 'Debian' or ansible_distribution == 'Ubuntu'
- name: Remove useless packages from the cache
apt:
autoclean: yes
when: ansible_distribution == 'Debian' or ansible_distribution == 'Ubuntu'
- debug:
msg: "{{ update.stdout_lines }}"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment