calvinbui.ansible_apt

Ansible Apt

Use this to install packages with apt and perform other tasks.

Requirements

None.

Role Variables

apt_install_packages: This is a list of packages you want to install using the apt module. If you don't need any packages, set it to an empty list [].

You can use all options available in the apt module here as well. Set them up just like you would in the apt module. For example:

apt_install_packages:
  - name: git
  - name: vim
  - name: htop
    state: present
  - upgrade: dist
  - update_cache: yes
    cache_valid_time: 3600
  - ...

Dependencies

None.

Example Playbook

- hosts: servers
  become: true
  pre_tasks:
    - name: Update apt cache.
      apt:
        update_cache: true
        cache_valid_time: 600
      changed_when: false
  roles:
   - role: ansible-apt

License

GPLv3

Author Information

Calvin Bui's Website

Informazioni sul progetto

Run apt commands via Ansible on Ubuntu

Installa
ansible-galaxy install calvinbui.ansible_apt
Licenza
Unknown
Download
2.3k
Proprietario
Soft tabs > spaces > tabs. I'm not a developer.