use afuse with fusedav
I am able to use afuse to mount my sshfs perfectly.
A lot of customers or sites won't allow outgoing ssh access which invalidates the sshfs solution, a number of sites also force http(s) access through a proxy. This lead me to use an 'owncloud' webdav apache server running out there where I store on my files when I am on the go.
I have been trying to make afuse work with fusedav but I have a bit confused with the parameters, specially where it regards to the %m expansion.
fusedav is handy because it doesn't require entries in /etc/fstab, its proper fuse. It is executed like this: fusedav -u username -p password https://mycloudserver/owncloud/files/webdav.php ~/mountpoint/owncloud
my files can then be accessed on ~/mountpoint/owncloud
afuse -d -f -o timeout=20 -o intr -o mount_template="fusedav -u username -p password https://mycloudserver/owncloud/files/webdav.php /home/azul/mountpoint/owncloud" -o unmount_template="fusermount -u -z /home/azul/mountpoint/owncloud" ~/mountpoint/owncloud
my problem here, is that I think afuse expects me to cd into ~/mountpoint/owncloud/
I don't want to mount multiple mountpoints on demand (as in the sshfs examples), only the davfs owncloud mountpoint. Is afuse flexible for this ? (I haven't looked into the code yet, thought of asking first)
-jorge
afuse is designed to auto-mount children of the afuse root when accessed.
If you only have one mountpoint, it sort of defeats the purpose.
Why don't you just use fusedav directly?
for the same reason I could choose to use autofs + sshfs instead of afuse. Your tool provides an unique way of automounting shares without any root access, with afuse I don't have to mangle with ssh public keys, or davfs2 secrets and certificates under /etc.
It can all be done within /home/user, that's pretty unique. No other tool provides that in userspace. fusedav doesn't provide a mechanism to unmount the mountpoint after 'n' seconds in the way that your tool does with '-o timeout='n''. I can achieve that with autofs but it requires root access to edit files in /etc/. Your tool and approach is the right way of delivering this, it should all be managed within userspace.
I have hacked my way around your afuse+sshfs setup by setting the global root mountpoint to ~/.mnt/sshfs and building symlinks in ~/mnt/serverA pointing to ~/.mnt/sshfs/user@serverA. This way I can simply browse down that symlink and afuse mounts the mountpoint automatically, and the user doesn't need to remember the name of the serverA. I am trying to achieve the same with the fusedav mountpoint.
-jorge
On 21 March 2013 00:47, ⨵⫝⨴ [email protected] wrote:
afuse is designed to auto-mount children of the afuse root when accessed.
If you only have one mountpoint, it sort of defeats the purpose.
Why don't you just use fusedav directly?
— Reply to this email directly or view it on GitHubhttps://github.com/pcarrier/afuse/issues/2#issuecomment-15213431 .
We're talking about fusedav here though, so I don't see how ssh public keys or davfs2 or anything alike would have to go into /etc.
fusedav can run as your user exactly like afuse, and AFAICT doesn't need to be unmounted.
So could you explain precisely why you don't just use fusedav directly?
Not using subdirectories seems hard, and would require a lot of changes to the code. afuse needs to "see" whenever something is accessed to handle automatic unmounts correctly, and we don't have a much better way to do that.