Is there a DM-independent way to set XAUTHORITY in my Synergy upstart script?

Jason Heeris jason.heeris at gmail.com
Thu Nov 28 00:48:03 UTC 2013


I use synergy[1] so that I can use a single mouse and keyboard across two
computers. While there are instructions for getting it to start
automatically when eg. lightdm starts, this is prone to annoyances (eg. the
lightdm login screen somehow forces synergy to use a single monitor
boundary, you can't restart the service without restarting lightdm).

I had written an upstart conf file for 12.10[2] that allowed synergy to act
as a service, and thus could restart on video configuration changes (or be
restarted manually in the event of crashes). But I need to set XAUTHORITY
somehow (and possibly DISPLAY, and maybe others...), and the only
DM-independent way to do that was with some scripts that just happened to
be sitting in /usr/share/acpi-support/power-funcs.

These are gone now (in 13.10), I think because they existed only to allow
integration with ConsoleKit, and ConsoleKit has been replaced by logind.

So my question is: is there a way to get a sensible value for XAUTHORITY
and DISPLAY in an upstart conf file that doesn't require special-casing
every different display manager? Or, if not, is there a page somewhere that
documents how the different display managers set these?

Thanks,
Jason

[1] http://synergy-foss.org/
[2] https://lists.ubuntu.com/archives/ubuntu-devel/2013-February/036485.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-devel/attachments/20131128/8eb0865b/attachment-0001.html>


More information about the ubuntu-devel mailing list