dockergoogle-cloud-platformgoogle-cloud-run

Can I change the owning user of a volume mount in cloud run?


I have a cloud run instance that with a volume mount that mounts a storage bucket into the filesystem. By default the volume mount is owned by root and/or a user with uid -1 (the docs seem to imply both things.)

The docs documentation mentions that volume mounts are powered by FUSE And the FUSE options mention you can mount the directory with a particular user as the owner. (--uid)

Can I edit the yaml file to force my volume mount to be mounted as a particular user somehow? Is there another option to create a filesystem mount with a given user that wouldn't cost me more then like 10 bucks a month?


Solution

  • Yes, you can pass flags to gcsfuse using the volume attribute mountOptions in the yaml as described in this section of the docs.