Skip to content

Ansible

Basic actions

Install collections from galaxy:

ansible-galaxy install -r requirements.yml

Run a playbook:

ansible-playbook -i inventory/ playbook.yml

Shutdown all servers in an inventory:

ansible all -i inventory/ -m shell -a "shutdown -h now" --become