Commit graph

112 commits

Author SHA1 Message Date
Diego Nicola Barbato
2f9f792a1e
services: slim: Update SLiM theme to 1.x.
* gnu/services/xorg.scm (%default-slim-theme-name): Change to "1.x".

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-06-10 23:11:15 +02:00
Timothy Sample
dcb3a0fe0a
services: gdm: Include user profile in D-Bus paths.
This partially addresses <https://bugs.gnu.org/35267>.

* gnu/services/xorg.scm (dbus-daemon-wrapper): When available, include
directories from '~/.guix-profile' in the search paths of the D-Bus
daemon.
2019-05-11 13:41:34 -04:00
Ludovic Courtès
e6b1a2248f
services: Log-in services now require "pam_loginuid".
Fixes <https://bugs.gnu.org/35553>.
Reported by Bruno Haible <bruno@clisp.org>.

* gnu/services/base.scm (login-pam-service): Pass #:login-uid? #t to
'unix-pam-service'.
* gnu/services/ssh.scm (lsh-pam-services, openssh-pam-services):
Likewise.
* gnu/services/xorg.scm (slim-pam-service): Likewise.
(gdm-pam-service): Likewise for "gdm-autologin" and "gdm-password".
* gnu/tests/base.scm (run-basic-test)["getlogin on tty1"]: New test.
* gnu/tests/ssh.scm (run-ssh-test): Add #:test-getlogin? parameter.
["getlogin"]: New test.
(%test-dropbear): Pass #:test-getlogin? #f.
2019-05-09 12:11:36 +02:00
Ludovic Courtès
6ad799d7c5
services: slim: Provide the 'xorg-server' Shepherd service.
This is a followup to 61569171d0.

* gnu/services/xorg.scm (slim-shepherd-service): Add 'xorg-server' to
'provision' when VT is "vt7".
2019-05-09 12:11:36 +02:00
Diego Nicola Barbato
61569171d0
services: slim: Allow SLiM to be started on multiple ttys.
This change makes it possible to add multiple SLiM services to an operating
system configuration by setting the new 'display' and 'vt' fields in their
configurations to different values.  Each SLiM service will get its own
authfile, logfile, lockfile, and shepherd service, which will start SLiM on a
different tty.

* gnu/services/xorg.scm: Export slim-configuration-display and
  slim-configuration-vt.
  (<slim-configuration>)[display, vt]: New fields.
  (slim-shepherd-service): Refactor let.
  [slim.cfg]: Use new fields for setting display_name, xserver_arguments,
  authfile, lockfile, and logfile.
  [shepherd-service][provision]: Name the shepherd service according to the
  value of 'vt'.
  [shepherd-service][start]: Delete the right lockfile.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-05-07 15:46:54 +02:00
Diego Nicola Barbato
b901b72545
services: slim: Honor the value of slim from slim-configuration.
Previously setting the slim field in slim-configuration would have no effect.

* gnu/services/xorg.scm (slim-shepherd-service): Remove unused let binding for
  slim.  Use (slim-configuration-slim config) instead of the default slim.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-04-29 09:33:55 +02:00
Ludovic Courtès
1361584983
services: localed: Do nothing for unconfigured keyboards.
* gnu/services/xorg.scm (localed-service-type)[package]: Return the
empty list when the 'keyboard-layout' field is #f.
[compose]: Use 'find' instead of 'first'.
2019-04-05 17:55:51 +02:00
Ludovic Courtès
3ef3bdf1cd
services: localed: Properly handle lack of a 'keyboard-layout'.
Fixes a type error when KEYBOARD-LAYOUT is #f.

* gnu/services/xorg.scm (localed-dbus-service): Return the empty list
when KEYBOARD-LAYOUT is #f.
2019-04-05 17:55:50 +02:00
Ludovic Courtès
0cf981a606
services: gdm: Properly handle empty extensions lists.
Fixes a bug whereby not extending GDM would lead us to do:

  (first '())

in the 'compose' method.

Regression introduced in 305a732a0a.

* gnu/services/xorg.scm (gdm-service-type)[compose]: Handle the case
where EXTENSIONS is empty.
[extend]: Handle the case where XORG-CONFIGURATION is #f.
2019-04-05 17:55:50 +02:00
Ludovic Courtès
305a732a0a
services: xorg: Add 'set-xorg-configuration'.
* gnu/services/xorg.scm (gdm-service-type)[compose, extend]: New fields.
(set-xorg-configuration): New procedure.
* doc/guix.texi (Keyboard Layout): Use it.
(X Window): Document it.
* gnu/system/examples/desktop.tmpl: Add 'keyboard-layout' fields.
2019-04-05 15:39:35 +02:00
Ludovic Courtès
607fcc7540
services: Add 'localed' service type and have GDM extend it.
This fixes a bug whereby GDM would always switch to US English keyboard
layout regardless to the configured Xorg keyboard layout.

* gnu/services/xorg.scm (<localed-configuration>): New record type.
(localed-dbus-service): New procedure.
(localed-service-type): New variable.
(gdm-service-type): Extend LOCALED-SERVICE-TYPE.
2019-04-05 15:39:35 +02:00
Tim Gesthuizen
bab7a49558
services: slim-configuration: Adapt exported getter methods.
Commit 554b860739 introduces changes to the
slim-configuration record without updating the exported methods.

* gnu/services/xorg.scm: Export slim-configuration-xorg and
  slim-configuration-sessreg.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-03-31 23:32:46 +02:00
Ludovic Courtès
631a6e6377
doc: Document 'gdm-service-type'.
* doc/guix.texi (X Window): Document 'gdm-service-type' and
'gdm-configuration'.  Take description of '.desktop' files from the
'slim-service-type' description.
* gnu/services/xorg.scm (gdm-service): Remove outdated comment.
2019-03-31 23:32:46 +02:00
Ludovic Courtès
70bb83b7b2
services: xorg: Fix cases where 'keyboard-layout' is #f.
This is a followup to 598757e038.

* gnu/services/xorg.scm (xorg-configuration->file): Check whether
'xorg-configuration-keyboard-layout' returns #f before calling
'keyboard-layout-options'.
2019-03-25 00:21:48 +01:00
Ludovic Courtès
598757e038
services: xorg: Add a 'keyboard-layout' field in <xorg-configuration>.
* gnu/services/xorg.scm (<xorg-configuration>)[keyboard-layout]: New
field.
(xorg-configuration->file)[input-class-section]: New procedure.
Use it.
* doc/guix.texi (X Window): Document 'keyboard-layout' field.

Co-authored-by: nee <nee-git@hidamari.blue>
2019-03-24 23:06:11 +01:00
Ludovic Courtès
554b860739
services: sddm, slim, gdm: Take an <xorg-configuration> record.
* gnu/services/sddm.scm (<sddm-configuration>)[xorg-server-path]
[xserver-arguments]: Remove.
[xorg-configuration]: New field.
(sddm-configuration-file): Adjust accordingly.
* gnu/services/xorg.scm (<slim-configuration>)[startx]: Remove.
[xorg-configuration]: New field.
(slim-shepherd-service, slim-service): Adjust accordingly.
(<gdm-configuration>)[x-server]: Remove.
[xorg-configuration]: New field.
(gdm-shepherd-service, gdm-service): Adjust accordingly.
* doc/guix.texi (X Window): Update accordingly.
2019-03-24 23:06:11 +01:00
Ludovic Courtès
b2e564515a
services: xorg: Define an <xorg-configuration> record type.
* gnu/services/xorg.scm (<xorg-configuration>): New record type.
(xorg-configuration-file): Remove.
(xorg-wrapper): Remove #:modules, #:configuration-file, and
 #:xorg-server; add optional 'config' parameter instead.  Adjust
accordingly.
(xorg-start-command): Likewise.
* doc/guix.texi (X Window): Document 'xorg-configuration'.  Update
'xorg-start-command' documentation.  Remove 'xorg-configuration-file'
documentation.
2019-03-24 23:06:11 +01:00
Ludovic Courtès
956607e340
services: xorg: Remove unused #:guile parameter.
* gnu/services/xorg.scm (xorg-wrapper): Remove #:guile, which was unused.
(xorg-start-command): Likewise.
(xinitrc): Likewise.
2019-03-24 23:06:11 +01:00
Jan Nieuwenhuizen
24f11b06bb
services: xorg: Enable override of xserver-arguments.
* gnu/services/xorg.scm (xorg-start-command): Add parameter #:xserver-arguments.
* doc/guix.texi (X Window): Document it.
2019-02-17 08:48:49 +01:00
Timothy Sample
41fa9f1815
services: gdm: Allow for custom X session scripts.
* gnu/packages/gnome.scm (gdm)[arguments]: Update pre-configure phase so
that GDM runs an X session script specified by the variable
GDM_X_SESSION; remove the '--enable-gdm-xsession' configuration
option.
* gnu/services/xorg.scm (<gdm-configuration>): Add 'x-session' field.
(gdm-shepherd-service): Set the GDM_X_SESSION variable.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-02-17 00:04:57 +01:00
Timothy Sample
7e61419892
services: gdm: Make dependencies explicit.
This commit removes the remaining implicit dependencies that the GDM
service had on the GNOME Desktop service.

* gnu/services/xorg.scm (gdm-configuration): Add a gnome-shell-assets
field for specifying any icons or fonts that the GNOME Shell theme
needs.
(gdm-shepherd-service): Remove environment variables pointing to
'/run/current-system' and set XDG_DATA_DIRS so that it points to
'gnome-shell' and its assets.
(gdm-service-type): Extend 'profile-service-type' to ensure that
necessary fonts are installed in the system profile.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-02-17 00:04:57 +01:00
Timothy Sample
1f564c1573
gnu: gdm: Run dbus-daemon via a wrapper script.
* gnu/packages/gnome.scm (gdm)[arguments]: Modify the pre-configure
phase so that GDM propagates the GDM_DBUS_DAEMON variable into the
session environment and uses its value to invoke dbus-daemon.
* gnu/services/xorg.scm (dbus-daemon-wrapper): New variable.
(<gdm-configuration>): Add 'dbus-daemon' field.
(gdm-shepherd-service): Set GDM_DBUS_DAEMON before invoking gdm.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-02-17 00:04:57 +01:00
Timothy Sample
e57c2adb2a
services: gdm: Remove etc service.
* gnu/packages/gnome.scm (gdm)[arguments]: Update pre-configure phase to
make GDM get the configuration file path from an environment variable.
* gnu/services/xorg.scm (gdm-etc-service): Remove function.
(gdm-configuration-file): New function.
(gdm-shepherd-service): Set GDM_CUSTOM_CONF before invoking GDM.
(gdm-service-type)[extensions]: Remove etc-service-type extension.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2019-02-17 00:04:56 +01:00
Ludovic Courtès
30d77f45eb
services: gdm: Disable debugging output.
* gnu/services/xorg.scm (gdm-etc-service)[gdm-configuration-file]:
Comment out debugging setting.
2019-02-10 23:25:01 +01:00
Pierre Neidhardt
fd96f94f7d
gnu: %default-xorg-modules: Include xf86-video-amdgpu.
* gnu/services/xorg.scm (%default-xorg-modules): Include xf86-video-amdgpu.
Rephrase comment to clarify the priority order.
2019-01-28 11:22:15 +01:00
Ludovic Courtès
65a67bf711
services: Use 'define-deprecated' for service procedures.
* gnu/services/base.scm (urandom-seed-service, gpm-service): Define
using 'define-deprecated'.
* gnu/services/messaging.scm (bitlbee-service): Likewise.
* gnu/services/networking.scm (dhcp-client-service): Likewise.
(ntp-service): Likewise.
* gnu/services/xorg.scm (slim-service): Likewise.
(gdm-service): Likewise.
2019-01-10 14:59:23 +01:00
Ludovic Courtès
01b3625df6
services: gdm: Add default value.
* gnu/services/xorg.scm (<gdm-configuration>)[x-server]: Add default
value.
(gdm-service-type)[default-value, description]: New fields.
(gdm-service): Mark as deprecated.
2019-01-10 14:59:22 +01:00
Timothy Sample
48c8d067d4
services: gdm: Enable auto-start.
GDM is now reliable enough to run automatically.

* gnu/services/xorg.scm (gdm-shepherd-service): Do not set 'auto-start?'
to '#f'.

Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
2018-12-30 10:20:41 +01:00
Timothy Sample
de409e8226
services: gdm: Remove 'allow-root?' option.
This option results in allowing all login attempts without asking for
credentials.  The name is confusing, but rather than rename it, we will
remove it, since it seems like a feature that no one would want.

* gnu/services/xorg.scm (<gdm-configuration>): Remove 'allow-root?'.
(gdm-pam-service): Do not use 'gdm-configuration-allow-root?'.

Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
2018-12-30 10:20:40 +01:00
Danny Milosavljevic
736e45a278
services: slim: Make the logged-in session show up in "w".
* gnu/services/xorg.scm (slim-shepherd-service): Use SESSREG to register X11
session.
* doc/guix.texi (slim-configuration): Document new field "sessreg".
2018-02-20 21:15:54 +01:00
Danny Milosavljevic
4e1efba42b
services: xorg: Import (ice-9 rdelim).
* gnu/services/xorg.scm (xinitrc): Import (ice-9 rdelim).
2018-02-17 02:48:00 +01:00
Tobias Geerinckx-Rice
d64e1746b9
doc, gnu: Fix spelling of screen-things.
* doc/guix.texi (X Window): Write 'screen locker' and 'screen saver' in
prose.
* gnu/services/xorg.scm (screen-locker-service): Likewise.
2018-01-29 23:27:53 +01:00
Ludovic Courtès
617e87bff1
services: xorg: Properly handle the case where ~/.xession is used.
Fixes a regression introduced in
65c0f43649 in the case where users provide
~/.xsession and SESSION is #f.

* gnu/services/xorg.scm (xinitrc): In the XSESSION-FILE case, check
whether SESSION is #f.
2017-12-04 10:36:48 +01:00
Ludovic Courtès
4afc903a8c
services: xorg: Add 'font-misc-misc' to the default font set.
Fixes <https://bugs.gnu.org/24279>.
Reported by John Darrington <john@darrington.wattle.id.au>.

* gnu/services/xorg.scm (%default-xorg-fonts): Add FONT-MISC-MISC.
2017-12-01 16:00:14 +01:00
Ludovic Courtès
65c0f43649
services: xorg: Remove WindowMaker as a default fallback.
* gnu/services/xorg.scm (xinitrc)[builder](system-profile)
(user-profile): New variables.
(xsession-command, find-session): New procedures.
When FALLBACK-SESSION is #f, find a valid session at run time.
* doc/guix.texi (X Window): Adjust accordingly, and insist that one
or more window managers must be installed.
2017-11-28 11:24:46 +01:00
Ludovic Courtès
b37f86d7a3
services: xorg: Document 'slim-configuration' and deprecate 'slim-service'.
* gnu/services/xorg.scm (<slim-configuration>): Provide default values
for all fields.
(slim-service-type)[default-value]: New field.
* doc/guix.texi (X Window): Remove 'slim-service' documentation.
Document 'slim-service-type' and 'slim-configuration'.
* gnu/services/desktop.scm (%desktop-services): Use 'slim-service-type'.
2017-11-28 11:24:45 +01:00
Ludovic Courtès
94b9abd942
services: slim: Remove unused 'bash' configuration field.
* gnu/services/xorg.scm (<slim-configuration>)[bash]: Remove.
(slim-service): Adjust accordingly.
2017-11-28 11:14:25 +01:00
Ludovic Courtès
d344f5a528
services: xorg: Allow users to specify a list of modules.
* gnu/services/xorg.scm (%default-xorg-fonts): New variable.
(xorg-configuration-file): Add #:modules and #:fonts.  Rewrite to return
a 'computed-file' that honors MODULES and FONTS.
(xorg-wrapper): Pass #:modules to 'xorg-configuration-file'.
(xorg-start-command): Add #:fonts.  Pass #:fonts and #:modules to
'xorg-configuration-file'.
* doc/guix.texi (X Window): Adjust documentation of 'xorg-start-command'
and 'xorg-configuration-file'.
2017-11-28 10:46:03 +01:00
Timothy Sample
3eda8dd614
services: gdm: Add environment variables.
While not an optimal solution (see comment), this makes GDM functional.

* gnu/services/xorg.scm (gdm-shepherd-service): Set PATH and XDG_DATA_DIRS
environment variables.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-11-07 18:09:13 +01:00
Andy Wingo
23290064c2
gnu: services: Add modesetting driver to xorg configuration path.
* gnu/services/xorg.scm (xorg-configuration-file): Add drivers path from
  xorg-server.  This includes the modesetting driver.

Signed-off-by: Andy Wingo <wingo@igalia.com>
2017-09-20 15:40:31 +02:00
Andy Wingo
6e99c01b4d
gnu: Add draft of gdm service.
* gnu/services/xorg.scm (%gdm-accounts, <gdm-configuration>)
(gdm-etc-service, gdm-pam-service, gdm-shepherd-service, gdm-service-programs)
(gdm-service-type, gdm-service): New public variables.  Not yet working.
2017-08-25 16:01:56 +02:00
Andy Wingo
92753a8bad
gnu: services: Refactor to separate X and startx wrappers.
* gnu/services/xorg.scm (xorg-wrapper): New public function.
(xorg-start-command): Use xorg-wrapper.
2017-08-25 16:01:56 +02:00
Marius Bakke
b35f442e62
gnu: Remove xf86-video-modesetting.
This is part of xorg-server since version 1.17:

https://cgit.freedesktop.org/xorg/xserver/commit/?id=35dc7c75150733dbcef8a18b6796f49a7c48ebee

* gnu/packages/xorg.scm (xf86-video-modesetting): Remove variable.
* gnu/services/xorg.scm (xorg-configuration-file, %default-xorg-modules):
Adjust accordingly.
2017-02-19 23:29:38 +01:00
8p8c
3126fd8820
services: xorg: Add ATI video driver to the default modules.
* gnu/services/xorg.scm (%default-xorg-modules): Add xf86-video-ati.

Signed-off-by: 宋文武 <iyzsong@gmail.com>
2016-10-06 20:46:50 +08:00
Ludovic Courtès
9e41130b14
system: Use 'file-append' to denote file names.
* gnu/services/avahi.scm, gnu/services/base.scm,
gnu/services/databases.scm, gnu/services/dbus.scm,
gnu/services/desktop.scm, gnu/services/dict.scm,
gnu/services/mail.scm, gnu/services/networking.scm,
gnu/services/sddm.scm, gnu/services/spice.scm,
gnu/services/ssh.scm, gnu/services/web.scm,
gnu/services/xorg.scm, gnu/system.scm: Replace the
 #~(string-append #$pkg "/bin/foo") idiom with
 (file-append pkg "/bin/foo").
2016-09-10 13:10:06 +02:00
David Craven
f2901d824a
services: Export initrc.
* gnu/services/xorg.scm (define-module): Export initrc.
2016-09-06 17:48:59 +02:00
Marius Bakke
5fd66a37d5
gnu: slim: Move to display-managers.scm.
* gnu/packages/display-managers.scm: New file.
* gnu/packages/slim.scm: Delete file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Adjust accordingly.
* gnu/services/xorg.scm: Likewise.
2016-09-01 14:36:49 +02:00
Tomáš Čech
24e964314e
services: Export *-service-type and *-configuration.
This allows users to use 'modify-services' and similar constructs for
all these service types.

* gnu/services/avahi.scm: export avahi-configuration.
* gnu/services/base.scm: export gpm-configuration and
rngd-configuration.
* gnu/services/databases.scm: export *-service-type and *-configuration.
* gnu/services/dbus.scm: export dbus-configuration.
* gnu/services/dict.scm: export dicod-service-type.
* gnu/services/lirc.scm: export lirc-configuration and
lirc-service-type.
* gnu/services/mail.scm: export dovecot-service-type.
* gnu/services/web.scm: export nginx-configuration and
nginx-service-type.
* gnu/services/xorg.scm: export screen-locker and screen-locker?.
* gnu/services/ssh.scm: export lsh-configuration and lsh-service-type.
* gnu/services/desktop.scm: export *-service, *-service-type
and *-configuration.
* gnu/services/networking.scm: export *-configuration
and *-service-type.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2016-07-21 18:53:27 +02:00
Ludovic Courtès
4ee96a7912
gnu: Switch to 'with-imported-modules'.
* gnu/services.scm (directory-union): Use 'with-imported-modules'
instead of the '#:modules' argument of 'computed-file'.
* gnu/services/base.scm (udev-rules-union): Likewise.
* gnu/services/dbus.scm (system-service-directory): Likewise.
* gnu/services/desktop.scm (wrapped-dbus-service):
(polkit-directory): Likewise.
* gnu/services/networking.scm (tor-configuration->torrc): Likewise.
* gnu/services/xorg.scm (xorg-configuration-directory): Likewise.
* gnu/system/install.scm (self-contained-tarball): Likewise.
* gnu/system/linux-container.scm (container-script): Likewise.
* gnu/system/linux-initrd.scm (expression->initrd): Likewise, and
remove #:modules parameter.
(flat-linux-module-directory): Use 'with-imported-modules'.
(base-initrd): Likewise.
* gnu/system/locale.scm (locale-directory): Likewise.
* gnu/system/shadow.scm (default-skeletons): Likewise.
* gnu/system/vm.scm (expression->derivation-in-linux-vm): Likewise.
* gnu/tests/base.scm (run-basic-test): Likewise.
* gnu/tests/install.scm (run-install): Likewise.
* doc/guix.texi (Initial RAM Disk): Update 'expression->initrd'
documentation.
2016-07-12 22:47:08 +02:00
Ludovic Courtès
f2ab925028 services: xorg: Fix ~/.xsession handling.
Fixes a regression introduced in c510cbb4ec.

* gnu/services/xorg.scm (xinitrc)[builder]: Add missing 'apply' when
XSESSION-FILE exists.
2016-03-24 11:01:07 +01:00