upstart session for dbus has hard coded .cache directory

Bug #1250668 reported by Cuero on 2013-11-12
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
dbus (Ubuntu)
Undecided
Unassigned

Bug Description

Description: Ubuntu 13.10
Release: 13.10

Package: dbus
Architecture: amd64
Version: 1.6.12-0ubuntu10

The file /usr/share/upstart/sessions/dbus.conf contains a hardcoded path to the .cache directory, making the use of XDG_CACHE_HOME variable non working.

The fix could to change line
echo "DBUS_SESSION_BUS_ADDRESS=${DBUS_SESSION_BUS_ADDRESS}" >$HOME/.cache/upstart/dbus-session
into
echo "DBUS_SESSION_BUS_ADDRESS=${DBUS_SESSION_BUS_ADDRESS}" >${XDG_CACHE_HOME:-$HOME/.cache}/upstart/dbus-session

I tested it and it works for me...

Cuero (cuerob) on 2013-11-12
affects: upstart (Ubuntu) → dbus (Ubuntu)
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in dbus (Ubuntu):
status: New → Confirmed
Cuero (cuerob) on 2014-03-19
affects: dbus (Ubuntu) → upstart (Ubuntu)
James Hunt (jamesodhunt) on 2014-03-20
affects: upstart (Ubuntu) → dbus (Ubuntu)
Cuero (cuerob) wrote :

I had changed to upstart package as this file is indeed in the upstart package. Is there a reason why you moved it back to dbus ?
dpkg -L upsstart list this file /usr/share/upstart/sessions/dbus.conf

James Hunt (jamesodhunt) wrote :

Actually that file lives in the dbus package:

$ dpkg -L upstart|grep dbus.conf
$ dpkg -L dbus|grep dbus.conf
/usr/share/upstart/sessions/dbus.conf
/etc/init/dbus.conf
$

Cuero (cuerob) wrote :

Ha yes you are totally right, sorry for the mistake. I got confused, some of those conf file are provided by upstart (like the one for logrotate).
Sorry for the confusion.
I actually changed the package because I figured that there was no activity at all on that bug even though it seemed a quick/obvious fix.
I should probably provide a patch rather than an textual description.
Thx, anyway.

Simon McVittie (smcv) wrote :

As of dbus/1.10.6-1ubuntu2 (the relevant change seems to have been in 1.8.12-1ubuntu1), the Upstart job creates that directory but then doesn't do anything with it, because the session bus address is now stored in XDG_RUNTIME_DIR.

This is one of several ways in which the Upstart job is far more complicated than it needs to be, for which I'll open a separate bug.

Simon McVittie (smcv) wrote :

> far more complicated than it needs to be

That may have been overstating it; in the absence of systemd-style socket activation, there's a limit to how much it can be simplified without having things try to connect to dbus-daemon before it's running :-(

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers