Linux – Set ACL

Use

$ setfacl -R -m u:seza:rwX,g:admin:rw-,o:r-- MyFolder

To change to permissions for the folder MyFolder and add

  • User “seza” has all permission: Read, Write, eXecute
  • Group “admin” has all permissions
  • Other has just Read persmission

Note on the options

  • -R is for recursive
  • Note the capital “X“, it will set the “execute” permission only if the file is a directory or has already execute permission for some user.

Use

$ setfacl -m default:u:seza:rwx,default:g:admin:rw-,o:r-- MyFolder

To change the permissions for the future files/folders that will be added