find /var/www/html -type d -exec chmod 755 {} ;find /var/www/html -type f -exec chmod 644 {} ;
- name: recursive chmod example
command: |
chmod -c -R ug=rw,o=r,a-x+X "{{item}}"
register: chmod_status
changed_when: chmod_status.stdout != ""
with_items:
- "/home/user/sample/dir"