Keep remote temp files

Preserve pushed module scripts under ~/.ansible/tmp to debug a failing module by hand

ANSIBLE_KEEP_REMOTE_FILES=1 ansible-playbook site.yml -vvvv --limit <host>

tool
ansible56 commands
tags
ansibledebugtroubleshooting

More ansible commands

  • ansible-playbook -i inventory/prod playbook.yml --diff

    Run playbook with diff output to see what changes

  • ansible-playbook -i inventory playbook.yml --limit host1,host2

    Run only against specific hosts from inventory

  • ansible-playbook -i inventory playbook.yml --tags install,configure

    Execute only tasks matching these tags

  • ansible-playbook -i inventory playbook.yml --skip-tags cleanup

    Skip tasks with the specified tags

  • ansible-playbook -i inventory playbook.yml --check --diff

    Simulate execution without making changes

all 56 ansible commands