Documentation

Usermap

Install usermap

Install the WebDAV Usermap Filesystem

# apt-get install hubzero-usermap

Configure Usermap

# apt-get install autofs
Edit /etc/auto.master by adding the following line
/webdav/home /etc/auto.webdav --timeout=60
Edit/create /etc/auto.webdav so that it has the following content
* -fstype=usermap,user=www-data,allow_other :&
# /etc/init.d/autofs restart
Add fuse to the /etc/modules file so that it is loaded on startup.

This automounts a usermap filesystem of a users home directory inside of /webdav/home on demand. This version of the users home directory is owned and accessible to the user www-data which allows WebDAV to serve its contents.

Test

# touch /home/myhub/apps/test
# ls -l /webdav/home/apps

You should see a list of files in apps's home directory ("test") which will appear to be owned by www-data.www-data

# mount -l

You should see something like:
mount.usermap on /webdav/home/apps type fuse.mount.usermap (rw,nosuid,nodev,allow_other)

Finally clean up.

# umount -f /webdav/home/apps
# rm /webdav/home/apps/test

Troubleshooting

If the test doesn't work, check if the fuse kernel module is loaded

#  lsmod | grep fuse
fuse                   54176  0 

If there is no output then try starting the kernel module manually

# modprobe fuse

Then try the test again

Last modified:

  • Copyright © 2022 Hubzero
  • Powered by Hubzero®