--- - name: Prepare hosts: all gather_facts: false tasks: - name: Install python for Ansible raw: test -e /usr/bin/python || (apt -y update && apt install -y python-minimal) become: true changed_when: false