I suggest you use bindfs.
bindfs allow multiple local users to read and write (create, delete, rename, modify...) all files (including newly created ones) from a shared directory and its subdirectories.
You can specify users by user name or group, it is very flexible.
The basic syntax (from the wiki page) is:
- Creating the shared directory
e.g. in the /home
directory:
sudo mkdir /home/shared
NOTE: If the directory already exist skip this step.
Allow only root to access it, we will set the permissions later with bindfs:
sudo chown root: /home/shared
sudo chmod 0700 /home/shared
- Setting the permissions with bindfs
Now use the bindfs command to mount the shared directory with altered permissions. Syntax of the command:
bindfs [options] dir mountpoint
Example:
sudo bindfs -o perms=0700,mirror-only=user1:user2:user3 /home/shared /home/shared
perms=0700
sets the permissions to 0700 (read/write for the owner, none for the group and other)
mirror-only=user1:user2:user3
user1, user2 and user3 will see itself as the owner of the files (user names are separated by a colon).
To automatically mount at boot, use fstab . Open fstab for editing with sudo nano /etc/fstab
and add a line
bindfs#/home/shared /home/shared fuse perms=0700,mirror-only=user1:user2:user3 0 0
See - Ubuntu wiki bindfs for group options and additional details.