Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- file: dest=/foo/bar/somedir owner=root group=apache mode=0775 recurse=yes
- - name: Ensure directories are 0755
- command: find {{ path }} -type d -exec chmod 0755 {} ;
- - name: Ensure files are 0644
- command: find {{ path }} -type f -exec chmod 0644 {} ;
- chmod -c -R ug=rw,o=r,a-x+X "{{top_dir}}"
- - 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"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement