--- - hosts: office general-use remote_user: root tasks: - name: delete nologin file: path={{ item }} state=absent with_items: - '/etc/nologin'