playbook apt update code example
Example 1: role ansible update apt
- name: Upgrade all apt packages
apt: upgrade=dist force_apt_get=yes
Example 2: role ansible update apt
- name: Update apt-get repo and cache
apt: update_cache=yes force_apt_get=yes cache_valid_time=3600