Installazione
echo "deb http://ppa.launchpad.net/ansible/ansible/ubuntu trusty main" > /etc/apt/sources.list.d/ansible.list
apt-key adv --keyserver http://keyserver.ubuntu.com --recv-keys 93C4A3FD7BB9C367
apt update
apt install ansible
Test
mkdir ~/ansible
cd !$
cat > site.yml <<EOFile
---
- hosts: localhost
ignore_errors: yes
force_handlers: True
tasks:
- name: Set timezone to Europe/Rome
timezone:
name: Europe/Rome
- name: Install common packages
apt:
pkg:
- bzip2
- less
- screen
- rsync
- xclip
state: latest
EOFile
ansible-playbook site.yml
Riferimenti
https://docs.ansible.com/ansible/latest/installation_guide/intro_installation.html#installing-ansible-on-debian