FS#58032 - [kbfs] systemd service file doesn't work
Attached to Project:
Community Packages
Opened by Konstantin Gizdov (kgizdov) - Thursday, 29 March 2018, 22:30 GMT
Last edited by Eli Schwartz (eschwartz) - Tuesday, 03 April 2018, 13:11 GMT
Opened by Konstantin Gizdov (kgizdov) - Thursday, 29 March 2018, 22:30 GMT
Last edited by Eli Schwartz (eschwartz) - Tuesday, 03 April 2018, 13:11 GMT
|
Details
Description:
I think there is a couple of problems with the systemd service file. Firstly, the syntax should be: ExecStartPre=-/bin/sh -c 'fusermount -uz "$(keybase config get mountpoint|sed s/\x5c"//g)"' and not: ExecStartPre=-/bin/sh -c 'fusermount -uz "$(keybase config get mountdir|sed s/\x5c"//g)"' Doesn't probably matter too much, but the official docs say to use 'keybase config set mountpoint /path' and took me quite a while to figure out why my service was failing. I know it comes shipped like this, I'll make a pull request on GitHub. Second issue is the service fails with the following error: fusermount: entry for /home/gizdov/keybase not found in /etc/mtab however, an entry does exist (was created automatically) like this: /dev/fuse /home/gizdov/keybase fuse rw,nosuid,nodev,relatime,user_id=1000,group_id=1000 0 0 Steps to reproduce: 1. install kbfs 3. run `keybase config set mountpoint/mountdir /keybase` 2. run `systemctl --user start kbfs` |
This task depends upon
Closed by Eli Schwartz (eschwartz)
Tuesday, 03 April 2018, 13:11 GMT
Reason for closing: Not a bug
Additional comments about closing: The fact that everything works as expected, is a subtle clue that everything is working as expected. Also this is upstream code...
Tuesday, 03 April 2018, 13:11 GMT
Reason for closing: Not a bug
Additional comments about closing: The fact that everything works as expected, is a subtle clue that everything is working as expected. Also this is upstream code...
The official docs are wrong then (which ones though)? mountdir is what it created on my system, it is what their run_keybase script tries to create, and it is what their service file consults. As a result of which, it is what I'm fairly sure it uses internally....
EDIT: like I thought, this is defined in https://github.com/keybase/client/blob/607fc79192221b8eb1a9e770f609f5dacd2d5b9d/go/libkb/config.go#L798
Regarding fusermount not seeing your mountpoint, I'm not sure what I'm supposed to do about that... it works for me, the error message comes from fusermount not from keybase, and the most likely explanation I guess is that your kbfs wasn't mounted until after the error message (this is why the ExecStartPre command is permitted to fail).