least-authority-wrapper for bitlbee-service-type breaks Bonjour support

  • Open
  • quality assurance status badge
Details
2 participants
  • Ludovic Courtès
  • Ricardo Wurmus
Owner
unassigned
Submitted by
Ricardo Wurmus
Severity
normal

Debbugs page

R
R
Ricardo Wurmus wrote 5 days ago
(address . bug-guix@gnu.org)
878qrpgfeh.fsf@elephly.net
The bitlbee-service-type uses the least-authority-wrapper to run bitlbee
in a container. A side effect when using bitlbee-purple is that the
Bonjour protocol no longer works as bitlbee cannot connect to the local
mDNS server:

Toggle snippet (10 lines)
<@rekado> account add bonjour rekado
<root> Account successfully added with tag bonjour
<@rekado> account on
<root> Trying to get all accounts connected...
<root> bonjour - Login error: Unable to establish connection with the local
mDNS server. Is it running?
<root> bonjour - Logging in: Signing off..
<root> bonjour - Logging in: Reconnecting in 5 seconds..

It works fine when running bitlbee manually.

The Bonjour protocol allows for serverless messaging, which is also used
by the Sugar desktop's Chat activity.

--
Ricardo
L
L
Ludovic Courtès wrote 2 days ago
(name . Ricardo Wurmus)(address . rekado@elephly.net)(address . 75390@debbugs.gnu.org)
87ikqpwu61.fsf@gnu.org
Hello!

Ricardo Wurmus <rekado@elephly.net> skribis:

Toggle quote (14 lines)
> The bitlbee-service-type uses the least-authority-wrapper to run bitlbee
> in a container. A side effect when using bitlbee-purple is that the
> Bonjour protocol no longer works as bitlbee cannot connect to the local
> mDNS server:
>
> <@rekado> account add bonjour rekado
> <root> Account successfully added with tag bonjour
> <@rekado> account on
> <root> Trying to get all accounts connected...
> <root> bonjour - Login error: Unable to establish connection with the local
> mDNS server. Is it running?
> <root> bonjour - Logging in: Signing off..
> <root> bonjour - Logging in: Reconnecting in 5 seconds..

I never used this feature, but I suspect the patch below should fix it:
Toggle diff (17 lines)
diff --git a/gnu/services/messaging.scm b/gnu/services/messaging.scm
index a914d0f89e..f796afbc82 100644
--- a/gnu/services/messaging.scm
+++ b/gnu/services/messaging.scm
@@ -850,6 +850,12 @@ (define bitlbee-shepherd-service
(file-system-mapping
(source "/run/current-system/locale")
(target source))
+ (file-system-mapping ;for Avahi
+ (source "/var/run/dbus")
+ (target source))
+ (file-system-mapping
+ (source "/run/avahi-daemon")
+ (target source))
(file-system-mapping
(source conf)
(target conf)))
Only problem is that things may go wrong if these directories don’t
exist.

So I think we should add a ‘bonjour?’ field in the config record, add
these mapping conditionally, and also add a Shepherd requirement on
‘avahi-daemon’.

Toggle quote (3 lines)
> The Bonjour protocol allows for serverless messaging, which is also used
> by the Sugar desktop's Chat activity.

Interesting!

Ludo’.
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 75390@patchwise.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 75390
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch