I have a Linux file server with some shared directories. These directories are sometimes accessed over SFTP, and sometimes by users with shells. Regardless of how these directories are accessed, I would like to ensure that:
- all files in the shared directory are always readable and writable by all users in the "fileserver" group (the moral equivalent of
g+rw
) - all directories in the shared directory are always traversable by all users in the "fileserver" group (the moral equivalent of
g+x
) - all files in the shared directory are never executable by anyone (the moral equivalent of
g-x
)
I have a vague recollection that I've done this before with setfacl
but I am not sure how.