Ansible is getting very popular for every department of IT operations. There are multiple ways to edit the plaoybook, but one of my favorite is the vim editor. Indentation is very important while working with Ansible Playbook, myself ran around while editing the playbook, so i though would need to document it around for people who are looking for the vim setting to be used for the Ansible Playbook.
Have the following setting in the ~/.vimrc file.
autocmd FileType yaml setlocal ai ts=2 sw=2 et