- hosts: [{{host}}] sudo: yes vars: admin_user: {{admin_user}} admin_password: {{admin_password}} tasks: - file: path={{config_dir}} state=directory - template: src={{templates_dir}}/rabbitmq.conf dest={{config_dir}}/rabbitmq.conf