sudo apt install -y software-properties-common
sudo add-apt-repository --yes --update ppa:ansible/ansible
sudo apt install -y ansible
To simulate the playbook execution without applying changes, use the --check
option:
ansible-playbook -i inventory.yml playbook.yml --ask-become-pass --check
To execute the playbook and apply the changes, run:
ansible-playbook -i inventory.yml playbook.yml --ask-become-pass
ansible-playbook -i inventory.yml playbook.yml --tags "grafana,nvim" --ask-become-pass
Test