---
# file: main.yml
- hosts: fotk
remote_user: fakesudo
tasks:
- name: create a developer user
user: name={{ user }}
password={{ password }}
https://docs.ansible.com/playbooks_roles.html#roles
If the play still has a ‘tasks’ section, those tasks are executed after roles are applied.
If you wish to run tasks before or after roles are executed, you need to list these under pre_tasks
and post_tasks
. Thus, there is no way to run "loose" tasks between two roles. You might want to create a dedicated role for these tasks.