--- - name: combination of importing both task as well as variable hosts: nodes # vars_files: # - /root/playbooks/imp_variable.yml tasks: - name: Deleting other user through import tasks import_tasks: /root/playbooks/userdel2.yml # - name: importing combine variable from other file # user: # name: "{{ 'username' }}" # state: absent ...