Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 644842 - app-crypt/keybase[kbfs] creates a directory at $ROOT/keybase
Summary: app-crypt/keybase[kbfs] creates a directory at $ROOT/keybase
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Nicolas Bock
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2018-01-17 10:25 UTC by Simon
Modified: 2018-09-27 07:07 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
patch to fix run_keybase to mount kbfs under ~/keybase (keybase-fix-run_keybase-to-mount-keybase-directory-under-HOME.patch,1.53 KB, patch)
2018-01-17 10:25 UTC, Simon
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon 2018-01-17 10:25:48 UTC
Created attachment 515144 [details, diff]
patch to fix run_keybase to mount kbfs under ~/keybase

run_keybase from app-crypt/keybase starts keybase and mounts the kbfs filesystem, but it does so in /keybase. Which is obviously not acceptable.

Looking at the existing bugs for this (https://github.com/keybase/client/issues/4739, https://github.com/keybase/keybase-issues/issues/2306 and https://github.com/keybase/client/issues/2604 for example, but there are more) it seems the keybase devs are not very interested in getting this fixed.

So I guess we'll need to patch this ourselves or remove app-crypt/keybase (or just the kbfs option) from the tree.
I've used this patch and it works in that in now mounts the keybase directory in ~/keybase where it should've been from the start.
Comment 1 Nicolas Bock gentoo-dev 2018-02-20 20:59:04 UTC
Hi Simon, thanks for the bug report. Could you give me what steps I need to take to reproduce this issue? Thanks!
Comment 2 Simon 2018-02-20 21:28:25 UTC
Hi Nicolas,

The only thing you need to do is execute have keybase < 1.0.41 and kbfs installed and then run:

 run_keybase

That script will do some things including creating the /keybase directory


P.S. 1.0.41 actually still creates /keybase but in that case it's a symlink to a folder in $HOME. But because of 647930 I haven't been able to try it so far.
Comment 3 Nicolas Bock gentoo-dev 2018-02-20 21:54:03 UTC
Hi Simon,

thanks for the information! Could you update your portage tree and give it another go? I don't think it's going to fully work yet, but it should be closer. I am looking through your patch, by the way, and am considering to add it.

Thanks!
Comment 4 Simon 2018-02-22 09:29:53 UTC
Hi Nicolas,

Unfortunately my patch doesn't work anymore for versions > 1.0.39 because of the changes from this PR https://github.com/keybase/client/pull/10250
So I've masked versions > 1.0.39 for now.

keybase now always uses /keybase for the first user and I've found no quick way to fix that.
I've asked if there's a way to override this behavior https://github.com/keybase/client/pull/10250#issuecomment-367617900
Comment 5 Kalin KOZHUHAROV 2018-03-05 11:44:16 UTC
Seems like we'll get rid of the /keybase requirement, 1.0.44 works now without the patch (after bug #649634).
Comment 6 Nicolas Bock gentoo-dev 2018-03-05 15:37:51 UTC
Thanks!
Comment 7 Simon 2018-03-05 17:02:51 UTC
(In reply to Kalin KOZHUHAROV from comment #5)
> Seems like we'll get rid of the /keybase requirement, 1.0.44 works now
> without the patch (after bug #649634).

Has anything changed on the keybase side? There have been no updates in the issue on GitHub regarding the /keybase directory and I haven't seen any commits related to it as well after PR https://github.com/keybase/client/pull/10250, though I might have missed something of course :)
Comment 8 Kalin KOZHUHAROV 2018-03-05 21:16:01 UTC
... it seems to work without requiring /keybase in 1.0.44, it mounts by default into ~/.local/share/keybase/fs and suggests to add a symlink from ~/keybase

I'll be really glad when this mess is sorted out, it is all over their issue tracker.
Comment 9 Simon 2018-03-05 22:09:41 UTC
(In reply to Kalin KOZHUHAROV from comment #8)
> ... it seems to work without requiring /keybase in 1.0.44, it mounts by
> default into ~/.local/share/keybase/fs and suggests to add a symlink from
> ~/keybase
> 
> I'll be really glad when this mess is sorted out, it is all over their issue
> tracker.

Ohw, that sounds good/would be nice if it now works that way.

You're not by any chance the second/third/etc user to use it on your machine?
The behavior introduced with 1.0.41 made /keybase only available for the first user to execute run_keybase, all other users got that ~/.local mount and the message you mentioned.
Comment 10 Nicolas Bock gentoo-dev 2018-06-21 09:05:00 UTC
Could you try this again for the most recent version 2.1.0? Quite a bit has changed in terms of how things are mounted.
Comment 11 Nicolas Bock gentoo-dev 2018-06-26 20:12:49 UTC
Please open another ticket if this is still an issue.
Comment 12 Simon 2018-09-27 07:07:27 UTC
Hi Nicolas, it seems like we need to add a file /etc/keybase/config.json with the following contents

{
  "disable-root-redirector": true
}

To prevent the /keybase directory from being used/created.
See the keybase docs for more info https://keybase.io/docs/kbfs/understanding_kbfs#root-redirector

I can make a PR to add that file if you want?