xdg and /etc/qubes/autostart

120 views
Skip to first unread message

Achim Patzner

unread,
Sep 5, 2016, 4:31:21 AM9/5/16
to qubes-users
Hi!


Is there any documentation regarding xdg and overrides in
/etc/qubes/autostart? I didn't find anything telling me what to put into
an override file in order to restrict something to exactly one VM
8sys-usb in this case)... Are there any examples?



Achim

Marek Marczykowski-Górecki

unread,
Sep 5, 2016, 5:18:01 AM9/5/16
to Achim Patzner, qubes-users
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
If you just want to start something in one VM, use the standard XDG way
to do that - place files in ~/.config/autostart (as ~ is not shared
across VMs).

As for /etc/qubes/autostart docs - there should be README.txt.

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJXzThEAAoJENuP0xzK19csNHAH/RWuumgLbtNw7+vD7KSnVZkD
PzgbsYjjAJMKEU+IZ7Gkhqzgyic1gtAQHDY0qGnl9ZTyg3ZBJ+SxT7aHXcbA+rxi
6ijEyn7iNjpzA6SI8rHYEFRZP1ZH7arIP5Xc8Z9WX5jpTeL9yrW70c9B8Ggf2/Ps
W7w+07nfmErujO4shWtMY8EkMesy+KgeRCy0qMGVSnwUFDbKE87GWt3ODUHBTvPg
tNQpT4BM4ZQzCmURmmol/Zva7XuBZ3Bb9I/jC8Tv7YpV9cdlXWPA6WKD0a2J4Gel
zI6MlLlUERaTc7WFA3cDPyo60O7mQQ4VnMq8uSBMgiqumH++UBlkmBNB/yOtvTY=
=Sk/7
-----END PGP SIGNATURE-----

Achim Patzner

unread,
Sep 5, 2016, 5:26:09 AM9/5/16
to qubes...@googlegroups.com
Am 05.09.2016 um 11:17 schrieb Marek Marczykowski-Górecki:
> On Mon, Sep 05, 2016 at 10:31:17AM +0200, Achim Patzner wrote:
> > Is there any documentation regarding xdg and overrides in
> > /etc/qubes/autostart? I didn't find anything telling me what to put into
> > an override file in order to restrict something to exactly one VM
> > 8sys-usb in this case)... Are there any examples?
>
> If you just want to start something in one VM, use the standard XDG way
> to do that - place files in ~/.config/autostart (as ~ is not shared
> across VMs).

Wouldn't that require to have someone log in?

> As for /etc/qubes/autostart docs - there should be README.txt.

There is a README telling to put additional entries into
/etc/qubes/autostart but it does not mention anything about _what_ to
put there.

Besides: Imagine you wanted to install solaar on sys-usb and start it on
boot. What would you do to get it running without launching it by hand?


Achim

Marek Marczykowski-Górecki

unread,
Sep 5, 2016, 5:42:42 AM9/5/16
to Achim Patzner, qubes...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Mon, Sep 05, 2016 at 11:26:03AM +0200, Achim Patzner wrote:
> Am 05.09.2016 um 11:17 schrieb Marek Marczykowski-Górecki:
> > On Mon, Sep 05, 2016 at 10:31:17AM +0200, Achim Patzner wrote:
> > > Is there any documentation regarding xdg and overrides in
> > > /etc/qubes/autostart? I didn't find anything telling me what to put into
> > > an override file in order to restrict something to exactly one VM
> > > 8sys-usb in this case)... Are there any examples?
> >
> > If you just want to start something in one VM, use the standard XDG way
> > to do that - place files in ~/.config/autostart (as ~ is not shared
> > across VMs).
>
> Wouldn't that require to have someone log in?

I'm talking about ~/.config/autostart in VM.
It is handled at VM startup (or more precisely - when GUI connects).
Yes, this do mean it is executed only if someone is logged in to dom0.

> > As for /etc/qubes/autostart docs - there should be README.txt.
>
> There is a README telling to put additional entries into
> /etc/qubes/autostart but it does not mention anything about _what_ to
> put there.

There is even an example...
Ah, you mean possible values for OnlyShowIn and NotShowIn? Indeed it isn't
documented anywhere, I think. But you can look at a lot of examples
there. Possible values:
- X-QUBES - any VM
- X-AppVM - any AppVM (excludes TemplateVM, ProxyVM, NetVM)
- X-NetVM
- X-ProxyVM
- X-TemplateVM
- X-UpdateableVM (TemplateVM or StandaloneVM)
- X-NonUpdateableVM (template based VMs)

> Besides: Imagine you wanted to install solaar on sys-usb and start it on
> boot. What would you do to get it running without launching it by hand?

I see solaar fedora package comes with a file in /etc/xdg/autostart. So
in fact you want to _disable_ it in non-sys-usb VMs, right?

So two steps:
1. Disable it everywhere:
/etc/qubes/autostart/solaar.desktop.d/30_qubes.conf:

[Desktop Entry]
NotShowIn=X-QUBES;

2. Enable it in sys-usb:

ln -s /etc/xdg/autostart/solaar.desktop ~/.config/autostart/

The second one works because overrides in /etc/qubes/autostart are
applied only to files in /etc/xdg/autostart and not ~/.config/autostart
(as indicated in README).

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJXzT4MAAoJENuP0xzK19csEPcH/3wRj+ReHgu8RJPju6Dn4yWO
YNyw384ydVmUYA1NMTbrlojhU0Dgb9Nd7l9T1xgo/Gj8ytPu75bqCAekTveqMmgL
1loKa1NljHcqPLHT6RJLWcGR9vgF9efTQUUc1yxIzW3UIVNi8rPftC3LpJ9UcgEH
vuV4WoQrzp/qJnkO0NWSDpJEgbkepeetUuL4s30vFLoAZh05MbNOL+7EjuMmTKUE
OpEPDa+RJlAaaygNUB0mz1V51Z7WeJkEQnlplOQZCShXQKtSo79SFi+qltorPbbS
f67ZY8vm9sYi/eaghDHskzXv3/GELl/2RCJoIWvIFnOF2mBFz0JiCsvtvgv58+I=
=wG54
-----END PGP SIGNATURE-----
Reply all
Reply to author
Forward
0 new messages