exclude host ansible code example
Example: ansible exclude a host
# By using the '!' you exclude a host from a play.
ansible-playbook --limit 'myapp:!database3' myplay.yaml
# By using the '!' you exclude a host from a play.
ansible-playbook --limit 'myapp:!database3' myplay.yaml