--- - name: Delete Study block: - name: Remove study folder win_file: path: "{{ study_folder }}" state: absent - name: Delete study folders on T drive ansible.windows.win_file: path: "T:\\{{ item }}\\{{ study_code }}" state: absent with_items: ["Import", "Export"] - name: Delete AD group community.windows.win_domain_group: name: "{{ study_code }}" description: "{{ study_code }} study" path: "ou=Project Groups,dc={{ win_project }},dc=loc" scope: domainlocal category: security state: absent delegate_to: "{{ os_project }}-{{ win_project }}-dc01"