I am running ansible playbook with the limit flag.
ansible-playbook -i hosts --vault-password-file /etc/hostname playbooks/install.yml --tags "printa" --limit 'all:!vm'
but this causes localhost to be not found:
PLAY [Playing with Ansible and Git] *****************************************************************************
skipping: no hosts matched
PLAY [all] ******************************************************************************************************
.
.
This is my install.yml
---
- name: "Playing with Ansible and Git"
hosts: localhost
connection: local
tasks:
- name: "just execute a ls -lrt command"
shell: "ls -lrt"
register: "output"
- debug: var=output.stdout_lines