From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:60077) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jOI23-00081p-MA for guix-patches@gnu.org; Tue, 14 Apr 2020 05:39:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jOI22-0007hi-70 for guix-patches@gnu.org; Tue, 14 Apr 2020 05:39:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:49957) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jOI22-0007hV-3Z for guix-patches@gnu.org; Tue, 14 Apr 2020 05:39:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jOI22-0005Uz-1q for guix-patches@gnu.org; Tue, 14 Apr 2020 05:39:02 -0400 Subject: [bug#35305] LightDM service Resent-Message-ID: From: L p R n d n References: <87sghcir5k.fsf@lprndn.info> <2d2d720d1fd6a6357a171e13953a593b@waegenei.re> Date: Tue, 14 Apr 2020 11:38:18 +0200 In-Reply-To: <2d2d720d1fd6a6357a171e13953a593b@waegenei.re> (Brice Waegeneire's message of "Sun, 12 Apr 2020 09:53:41 +0000") Message-ID: <874ktmjtkl.fsf@lprndn.info> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Brice Waegeneire Cc: 35305@debbugs.gnu.org Hello, Thanks again for the feedbacks. Brice Waegeneire writes: [...] > There is an error on vt1 at startup about some dbus stuff related to > =E2=80=9Caccountservice=E2=80=9D. The cursor theme isn't set as well as t= he icon theme,=20 > it > seems; it may come from some missing environment variable as NixOS set a > few of them in their service[0]. For the cursor, setting "XCURSOR_PATH" seems to solve the problem. Preparing a patch. As for dbus, from what I found at NixOS[0][1], it's a accountsservice bug. I'll send a bug report. In the meantime, it doesn't appear to affect LightDM too much so it might be ok...? > After digging in the new service file I keep wondering if it's the right > way to go about implementing it. I tried to set a simple setting > for `lightdm-gtk-greeter` and I ended up with the following which=20 > doesn't > look intuitive: > > (service lightdm-service-type > (lightdm-configuration > (greeter-configuration-file > (lightdm-gtk-greeter-configuration-file > (lightdm-gtk-greeter-configuration > (extra-config "hide-user-image=3Dtrue")))))) Yeah, far from elegant. Did it that way in case someone wanted to provide its own file but dropping lightdm-gtk-greeter-configuration-file gives one level less of nesting. > Furthermore `lightdm-service-type` only set a single seat while lightdm=20 > can > have many of them. So maybe there should be a lightdm-seat` record used=20 > as > a list of seats in `lightdm-service-type`. Each greater will be able to > expand `lightdm-service-type` by appending a seat to it. Then the > configuration could look like this: > > (service lightdm-service-type) > (service lightdm-gtk-greeter-service-type > (lightdm-gtk-greeter-configuration > (assets (list guix-artwork)) > (theme-name "Guix") > (extra-config "hide-user-image=3Dtrue"))) I didn't know one could use a different greeter for each seat. Indeed, it would be nice to have that feature! The only thing that bothers me is that you don't get a working default LightDM service by default. I feel that just adding (service lightdm-service-type) to your configuration should get you a fully working LightDM, specially for newcomers. Here one would lack a greeter. :/ I believe there is a solution that would give us the best of both worlds. If someone has a clue, an idea or even a patch, please share it! :) Also, merging as is and improving the service later is possible too. > > Using this approch would also avoid populating =E2=80=9C/etc=E2=80=9D, at= least for > `lightdm-grk-greeter`, since each greeter would be defined as a service=20 > and > could expand =E2=80=9C/etc=E2=80=9D if it really needs it. For `lightdm-g= tk-greeter` > specifically avoiding putting config in =E2=80=9C/etc/=E2=80=9D can be do= ne by compiling=20 > it > with `-DCONFIG_FILE` pointing to `/run/current-system` And `lightdm` can= =20 > be > started with `--config`. I will make a patch to use --config for lightdm. For lightdm-gtk-greeter, how would one put the config file in "/run/current-system"? Do we need to make a package out of it? > Here is an example in how to make a conjuration file procedure more > readable while keeping under the line length limit by using=20 > `match-record`: > > (define (lightdm-gtk-greeter-configuration-file config) > (match-record config > (theme-name icon-theme-name cursor-theme-name cursor-size background > extra-config) > (mixed-text-file "lightdm-gtk-greeter.conf" " > [greeter] > theme-name =3D " theme-name " > icon-theme-name =3D " icon-theme-name " > cursor-theme-name =3D " cursor-theme-name " > cursor-theme-size =3D " (number->string cursor-size) " > background =3D " background " > " extra-config " > "))) Way better! Preparing a patch for that. > BTW the default background could use one from Guix artwork repo like > =E2=80=9C(file-append %artwork-repository "/grub/GuixSD-fully-black-16-9.= svg")=E2=80=9D. Yeap! > WDYT? I may be completely off on the `lightdm-seat` part. > > [0]:=20 > https://github.com/NixOS/nixpkgs/blob/release-19.09/nixos/modules/service= s/x11/display-managers/lightdm-greeters/gtk.nix#L18 > > Cheers, > - Brice Have a nice day! L p R n d n