2

I'm working on it since a few hours but I'm not able to get it working.

I successfully mounted an existing GCS bucket (my-bucket) on a running instance. I, with my_user, am able to list and copy files from the mounted bucket. Now another user on the same machine needs to list and copy files form the same mounted bucket but he gets a "permission denied" error message.

I read the Access Permission section here. So I tried as follows:

  1. Created a group named "bucket-users": sudo groupadd bucket-users
  2. Added existing users: sudo useradd -G bucket-users user_name
  3. Mounted the bucket using --gid option: gcsfuse --gid 1008 my-bucket /mnt/my-bucket
  4. Mounted successfully:

$ ls -ltr $ drwxr-xr-x 1 my_user bucket-users 0 Sep 16 09:11 my-bucket

Result: I am able to work on the bucket, but other users from the group "bucket-users" aren't.

Where am I going wrong here?

Thanks!

toomuchkevin
  • 161
  • 2
  • 7

1 Answers1

2

The access permissions section of the document you linked to says this:

As a security measure, fuse itself restricts file system access to the user who mounted the file system (cf. fuse.txt). [...]

If you know what you are doing, you can override these behaviors with the allow_other mount option supported by fuse [...] Be careful, this may have security implications!

This isn't just about the UID and GID of the files, but rather the kernel itself won't let anybody else access the file system. You can override this with -o allow_other, but please beware that this may be a security issue.

jacobsa
  • 5,719
  • 1
  • 28
  • 60