Ansible role for installing pacman packages.
- Python 2
- Ansible 1.9 or higher
Role variables are in defaults/main.yml.
Whether to update caches or not: true
or false
.
A state of installing (or installed) packages: present
or latest
.
An array of packages to install.
An array of packages to remove.
- hosts: localhost
vars:
pacman_install:
- emacs
- vim
- zsh
roles:
- { role: itiut.pacman, tags: pacman }
python2
is required to run Ansible 1.9 but python
is linked to python3
on Arch Linux. So setting ansible_python_interpreter
to python2
is required.
In inventory:
[localhost:vars]
ansible_python_interpreter=python2
Or in playbook:
- host: localhost
vars:
ansible_python_interpreter: python2
MIT