From mboxrd@z Thu Jan 1 00:00:00 1970 From: Timothy Sample Subject: GDM future work Date: Sun, 30 Dec 2018 11:56:24 -0500 Message-ID: <87y387kl6v.fsf@ngyro.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:57408) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gdeOF-00082k-GG for guix-devel@gnu.org; Sun, 30 Dec 2018 11:56:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gdeOA-0003AT-1y for guix-devel@gnu.org; Sun, 30 Dec 2018 11:56:39 -0500 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:38857) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gdeO8-00033Z-3f for guix-devel@gnu.org; Sun, 30 Dec 2018 11:56:33 -0500 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id B3DE620F6F for ; Sun, 30 Dec 2018 11:56:25 -0500 (EST) Received: from mrblack (74-116-186-44.qc.dsl.ebox.net [74.116.186.44]) by mail.messagingengine.com (Postfix) with ESMTPA id 0BD5FE40A1 for ; Sun, 30 Dec 2018 11:56:25 -0500 (EST) List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org Hi Guix, I have been using GDM on GuixSD for the past few days, and I am quite happy with it. A few patches that make it usable just landed on master. Now, there is a lot of room left for cleaning it up, but I need some advice. The main issue is the way that GDM launches the session bus (the instance of D-Bus that manages the session). It launches it from a clean environment that has little more than what PAM gives from =E2=80=9C/etc/environment=E2=80=9D (and =E2=80=9C~/.pam_environment=E2=80= =9D, if it exists). The result is that D-Bus can=E2=80=99t find any services, because it doesn=E2=80=99t h= ave =E2=80=9CXDG_DATA_DIRS=E2=80=9D set. Currently, this is solved by patching GDM to thread =E2=80=9CXDG_DATA_DIRS= =E2=80=9D into the process the launches D-Bus, but that=E2=80=99s not great. There are at least two better options. (1) Extend the PAM environment service so that it puts important environment variables for D-Bus in =E2=80=9C/etc/environment=E2=80=9D. Thi= s is easy to do, and fits pretty naturally with the way that GDM works. (2) Set up a wrapper script for D-Bus like the wrapper script we currently use for X. This way, we could very precisely set up where the session bus looks for system and user service files. This seems to be more like =E2=80=9Cthe Guix way=E2=80=9D, but it would mean threading a =E2=80=9CGDM_DBUS_LAUNCH=E2=80=9D environment variable through the GDM code= (like we currently do with =E2=80=9CGDM_X_SERVER=E2=80=9D). Besides these two options, I get tempted to think even bigger. We could replace a lot of the GDM session initialization code with our own code, and then if we only had per-session Shepherd instances=E2=80=A6. That=E2= =80=99s probably too big for right now. :) I lean towards option 2, because my understanding is that, in general, Guix prefers static configuration over dynamic configuration. This means that the discoverability gained by option 1 is actually a liability, since it creates a way for dependencies to exist which are not declared statically. The other advantage that option 2 has is that it would be possible to find service files from the user=E2=80=99s profile.= By doing this, we avoid having to tell everyone about =E2=80=9C~/.pam_environm= ent=E2=80=9D and what to put in there to make D-Bus aware of services in the user=E2=80= =99s profile. Thoughts? Besides this, there are few straight-forward things to do. We need to make a =E2=80=9Clibgdm=E2=80=9D package that does not depend on =E2=80=9Cgn= ome-shell=E2=80=9D [1]. It would be nice to fill out the config record and get rid of the opaque configuration text file. We need documentation for GDM in the manual. Finally, I already miss the Guix logo from SLiM, so even if it is not the default, I would like a Guix theme to be available. :) I will chip away at these as I have time, but of course anyone is welcome to jump on them if I=E2=80=99m too slow. [1] https://lists.gnu.org/archive/html/guix-devel/2017-10/msg00231.html -- Tim