1
Fork 0
mirror of https://https.git.savannah.gnu.org/git/guix.git/ synced 2025-07-14 19:10:49 +02:00
Commit graph

531 commits

Author SHA1 Message Date
Mathieu Othacehe
7c820cd888
tests: Fix the gui installation tests.
This is a follow-up of: 4c017ccfe5. The
run-basic-test procedure is used for the gui installation tests, but the
etc-profile-d-service-type and etc-bashrc-d-service-type services that are now
needed are only defined in the test-basic-os procedure.

Build upon the introduction of the extra-tests argument to define the
etc-profile-d-service-type and etc-bashrc-d-service-type specific tests
directly in the test-basic-os procedure.

* gnu/tests/base.scm (run-basic-test): Move the etc-profile-d-service-type and
etc-bashrc-d-service-type dedicated tests to ...
(test-basic-os): ... that procedure, where the matching services are defined.

Change-Id: I050f5ab87e19889bc90cc1a375a3cc28ea9a43ab
2025-07-01 11:50:16 +02:00
Mathieu Othacehe
11b5443e48
tests: Support basic tests extension with an extra-tests argument.
* gnu/tests/base.scm (run-basic-test)[extra-tests]: New argument.

Change-Id: Ia3595638309738d3361c583c93a66e0a872adabe
2025-07-01 11:50:16 +02:00
Mathieu Othacehe
f3a8db842d
tests: Really test the etc-bashrc-d-service-type service.
Follow-up of: 4c017ccfe5.

The --init-file script will only be run in the context of an interactive
shell, which is not the case here. Use the `-i` argument instead to force an
interactive shell. That way, the test_bashrc_d.sh is now really executed.

* gnu/tests/base.scm (run-basic-test): Fix the etc-bashrc-d-service-type test.

Change-Id: I3d749f65f51ff103c76f4e3d60746ae963660329
2025-07-01 11:50:15 +02:00
Efraim Flashner
214aa26e5c
gnu: installer: Remove enlightenment desktop option.
* gnu/installer/services.scm (%system-services): Remove
enlightenment-desktop-service-type.
* gnu/tests/install.scm (installation-target-desktop-os-for-gui-tests):
Remove enlightenment-desktop-service-type.
* etc/manifests/cross-compile.scm (%system-packages): Remove
enlightenment.
* etc/manifests/release.scm (%system-packages): Remove enlightenment.

Change-Id: I79cd8fc13ea0fda5eef72aee783b26edc77dcb5e
2025-06-30 11:41:56 +03:00
Maxim Cournoyer
cfa2de2a77
services: Modernize and test nftables service.
* doc/guix.texi (Networking Services) <nftables>: Update doc.
* gnu/services/networking.scm (list-of-debug-levels?):
(debug-level?, maybe-list-of-debug-levels?):
(nftables-configuration): Rewrite using `define-configuration'.
[debug-levels]: New field.
(nftables-shepherd-service): Honor it.
* gnu/tests/networking.scm (%inetd-echo-port): Extract to top level.
(run-iptables-test): Adjust accordingly.
(make-nftables-os): New procedure.
(%default-nftables-ruleset-for-tests): New variable.
(%nftables-os): Likewise.
(%test-nftables): New test.

Change-Id: I2889603342ff6d2be6261c3de6e4fddd9a9bbe2d
2025-05-26 13:43:28 +09:00
Maxim Cournoyer
c743d646ee
system: Factorize bashrc default configuration.
This factorizes out the remaining bashrc bits from /etc/skel/.bashrc to a the
template used for both /etc/bashrc on Guix System and ~/.bashrc for
home-bash-service-type.

Rationale: The use of /etc/skel introduce state: the file is only copied
originally when the user account is created, and never (automatically)
refreshed again.

* gnu/system.scm (operating-system-etc-service):
<profile>: Guard against souring /etc/bashrc in non-interactive, SSH case.
<bashrc>: Use %default-bashrc, having migrated the remaining definitions to...
* gnu/system/shadow.scm (%default-bashrc): ... here.  Factorize aliases to...
* gnu/services.scm (%default-bash-aliases): ... here.
(%default-bashrc-d-aliases): New variable.
(%default-etc-bashrc-d-files): Include it in the default configuration.
* gnu/services/base.scm (%base-services): Register etc-bashrc-d-service-type.
* gnu/home/services/shells.scm (add-bash-configuration): Do not set PS1, now
part of %default-bashrc.
(home-bash-configuration) [guix-defaults?]: Update doc.
[aliases]: Set %default-bash-aliases as the default value.  Update doc.
* doc/guix.texi (Shells Home Services): Update documentation.
(Service Reference): Update example.

Change-Id: I340c614983a78fd20a9c4a9705e7fc542ae9b513
2025-05-26 13:43:03 +09:00
Maxim Cournoyer
4c017ccfe5
services: Add etc-bashrc-d-service-type.
* gnu/services.scm (files->bashrc-d-directory) New procedure.
(etc-bashrc-d-service-type): New service type.
* doc/guix.texi (Service Reference): Document it.
* gnu/tests/base.scm (test-basic-os): Test it.

Change-Id: Ibbb0f684de7aee296adedbce5b1192786d661af2
2025-05-26 13:43:03 +09:00
Maxim Cournoyer
279adf431b
services: Add etc-profile-d-service-type.
* gnu/services.scm (make-files->etc-directory)
(files->profile-d-entries): New procedures.
(etc-profile-d-service-type): New service type.
* doc/guix.texi (Service Reference): Document it.
* gnu/tests/base.scm (run-basic-test): Test it.

Change-Id: I45dde43a1b9603c3384b933ebd1d6e45dba146b9
2025-05-26 13:43:03 +09:00
Sughosha
b1d2483ebe
home: services: Add readymedia.
* gnu/home/services/upnp.scm: New file.
* gnu/local.mk: Register it.
* gnu/services/upnp.scm: Export readymedia-activation and
readymedia-shepherd-service.
(<readymedia-configuration>)[home-service?]: New field.
[cache-directory]: Adjust value depending on 'for-home?'.
[log-directory]: Ditto.
(readymedia-shepherd-service): Adjust 'requirement' and 'start' according to
'home-service?'.
(readymedia-activation): Adjust creating 'media-directories' with permissions
according to 'home-service?'.
* gnu/tests/upnp.scm (%readymedia-configuration-test): Configure port with
%readymedia-default-port.
* doc/guix.texi (Miscellaneous Home Services): Document Readymedia Service.
(Miscellaneous Services): Add cross-reference.

Change-Id: I5c48595d84a815d98e03c7f68a716f048903720c
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2025-05-18 22:55:54 +02:00
Alexey Abramov
efcf1a2334
services: dnsmasq: Add stats and reload shepherd actions.
* gnu/services/dns.scm (dnsmasq-service-reload-action): New function.
Implements SIGHUP handling for reloading configurations.
(dnsmasq-service-stats-action): New function. Implements SIGUSR1
handling for dumping statistics.
(dnsmasq-shepherd-service): Use new actions.
* doc/guix.texi: Document new actions with examples.
* gnu/tests/networking.scm (%test-dnsmasq): Add tests to verify the
functionality of new actions.

Change-Id: I31f0eb4b26a582e95f7bfdb240110c139f0e16cc
Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Modified-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
2025-05-16 17:01:11 +09:00
Maxim Cournoyer
3bb6147fdc
services: udev: Also create subsystem nodes at boot.
This is a more correct fix to CDROM/DVDROM events/auto-mounting than was made
in the now-reverted commit 670724edcf ("gnu: eudev: Fix optical discs
detection/auto-mounting.")

This changes causes the 60-block.rules udev rules file shipped with eudev to
correctly set the default polling period to 2000 ms on block devices, which is
necessary for kernel events to be fired for CDROM drives for example.  To
validate it is set:

  # cat /sys/module/block/parameters/events_dfl_poll_msecs
  2000

Before, it would return 0.

* gnu/services/base.scm (udev-shepherd-service): <#:start>: Add a 'udevadm
trigger --change=add --type=subsystems' invocation, so that it also creates
subsystem nodes, as done in Void Linux or LinuxFromScratch init scripts for
example.
* gnu/tests/base.scm (run-basic-test): Add test.

Fixes: <https://issues.guix.gnu.org/35584>
Change-Id: Idc0eb5640163b27e41b72cc0c1885412a60805c1
2025-05-14 22:10:44 +09:00
Maxim Cournoyer
fbf8b81971
tests: Fix (gnu tests base.scm) module indentation.
* gnu/tests/base.scm: Fix indentation.

Change-Id: I3432fafa2f5c2853a14b5d125cf9377786ca6594
2025-05-06 23:22:25 +09:00
Maxim Cournoyer
10cb04d8ac
tests: Fix indentation of (gnu tests base).
* gnu/tests/base.scm: Fix indentation.

Change-Id: I84ae82a8ce85ff0113a3eb1215b11c191d3929d6
2025-05-06 16:32:06 +09:00
Giacomo Leidi
9d216d2ae9
services: postgresql-role: Add support for password files.
This commit adds a password-file to the postgresql-role field.  It
allows users to provision Postgres roles with a set password.

* gnu/services/databases.scm (postgresql-role): Add password-file field.
(postgresql-role-configuration): Add requirement field.
(postgresql-create-roles): Add support for setting passwords from a
file without leaking passwords to the command line.
(postgresql-role-shepherd-service): Add support for customizable
requirements.
(postgresql-role-service-type): Pass on postgresql-role-configuration
fields values by default, this way user configured fields are not lost.
* gnu/tests/databases.scm: Test it.
* doc/guix.texi: Document the new field and fix the extension point example.

Change-Id: I3aabaa10b0c5e826c5aa874e5649e25a3508a585
Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
2025-05-02 15:32:25 +09:00
Maxim Cournoyer
5b981a2b5c
tests: elogind: Adjust expected output for new version.
* gnu/tests/desktop.scm (run-elogind-test): Adjust expected output of loginctl
commands.

Change-Id: I10c131872909ac18a85b8244327883549c76eac0
2025-04-25 10:42:16 +09:00
Maxim Cournoyer
c6ee7b0f79
tests: Fix failing 'guix-system-tests' derivation during 'guix pull'.
I have no idea why using specifications->packages in a system test OS breaks
this derivation; it'd be nice to find out.

* gnu/tests/messaging.scm (%pounce-os): Do not use `specifications->packages'.

Reported-by: Ada Stevenson <adanskana@gmail.com>
Reported-by: Ian Eure <ian@retrospec.tv>
Change-Id: Iea727bedecff7a140f895e456ef01503ad11dad0
2025-04-22 14:09:40 +09:00
Maxim Cournoyer
aab89b3d93
services: pounce: New service.
* gnu/services/messaging.scm (pounce-serialize-boolean):
(pounce-serialize-string, pounce-serialize-list-of-strings)
(pounce-serialize-pair, power-of-two?)
(pounce-serialize-number, pounce-serialize-power-of-two)
(pounce-serialize-port, pounce-serialize-maybe-boolean)
(pounce-serialize-maybe-number, pounce-serialize-maybe-pair)
(pounce-serialize-maybe-port, pounce-serialize-maybe-port
(pounce-maybe-power-of-two, pounce-serialize-maybe-string)
(pounce-serialize-maybe-list-of-strings): New procedures.
(pounce-configuration): New configuration.
(pounce-activation): New procedure.
(serialize-pounce-configuration, pounce-wrapper): Likewise.
(pounce-service-type): New service type.
* gnu/tests/messaging.scm (ngircd-tls-cert-service-type): New variable.
(%pounce-os): Likewise.
(run-pounce-test): New procedure.
(%test-pounce): New test.
* doc/guix.texi (Messaging Services): Document it.

Change-Id: I4bbd2bc4821072a93c2c4017b86df329c4b240cb
Reviewed-by: Ludovic Courtès <ludo@gnu.org>
2025-04-22 11:35:24 +09:00
Ludovic Courtès
e2583b5a17
services: guix: Allow ‘guix-daemon’ to run without root privileges.
* gnu/services/base.scm (run-with-writable-store)
(guix-ownership-change-program): New procedures.
(<guix-configuration>)[privileged?]: New field.
(guix-shepherd-service): Rename to…
(guix-shepherd-services): … this.   Add the ‘guix-ownership’ service.
Change ‘guix-daemon’ service to depend on it; when unprivileged,
prefix ‘daemon-command’ by ‘run-with-writable-store’ and
omit ‘--build-users-group’; adjust socket activation endpoints.
(guix-accounts): When unprivileged, create the “guix-daemon” user and
group in addition to the others.
(guix-service-type)[extensions]: Adjust to name change.
* gnu/tests/base.scm (run-guix-daemon-test): Add ‘name’ parameter.
(%test-guix-daemon): Adjust accordingly.
(%test-guix-daemon-unprivileged): New test.
* doc/guix.texi (Base Services): Document ‘privileged?’.
(Migrating to the Unprivileged Daemon): Explain that this is automatic
on Guix System.

Reviewed-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Change-Id: I28a9a22e617416c551dccb24e43a253b544ba163
2025-04-20 18:52:59 +02:00
Ludovic Courtès
2c7c059e0b
tests: guix-daemon: Wait for the ‘guix-daemon’ service to be up.
* gnu/tests/base.scm (run-guix-daemon-test): Add “guix-daemon service is
up” test.

Change-Id: I4d44a1248599fec45c854c285d4da201c30eb00c
2025-04-20 18:50:52 +02:00
Ludovic Courtès
6367e69f50
tests: guix-daemon: Send system log output to /dev/console.
* gnu/tests/base.scm (%daemon-os): New variable.
(%test-guix-daemon): Use it.

Change-Id: Iea31808cc59e94971ea4cbc12d565c94348bf7a4
2025-04-20 18:50:52 +02:00
Maxim Cournoyer
19de75a165
tests: Streamline ngircd test image.
* gnu/tests/messaging.scm (%ngircd-os): Remove openssh-service-type and screen
package.

Change-Id: Ia08225500c544087676606ef7805037fa2b0ea5b
2025-04-14 10:34:52 +09:00
Maxim Cournoyer
c9524b5841
services: Add ngircd-service-type.
* gnu/services/messaging.scm (pascal-case, ngircd-serialize-string)
(ngircd-serialize-boolean, ngircd-serialize-file-like)
(ngircd-serialize-list-of-strings, ngircd-serialize-list-of-ports)
(ngircd-serialize-number, ngircd-serialize-port)
(string-or-number?, ngircd-serialize-string-or-number): New procedures.
(ngircd-global, ngircd-limits, ngircd-options, ngircd-ssl)
(ngircd-operator, ngircd-server, ngircd-channel)
(ngircd-configuration): New configurations.
(serialize-ngircd-global, serialize-ngircd-limits)
(serialize-ngircd-options, serialize-ngircd-operator)
(serialize-list-of-ngircd-operators, serialize-ngircd-server)
(serialize-ngircd-channel, serialize-list-of-ngircd-channels)
(serialize-ngircd-configuration): New procedures.
(list-of-ngircd-operators?, list-of-ngircd-servers?)
(list-of-ngircd-channels?): New predicates.
(ngircd-generate-documentation): New procedure.
(ngircd-user+group, ngircd-account, ngircd-wrapper): Likewise.
(ngircd-shepherd-service): New shepherd service.
(ngircd-service-type): New service type.
* gnu/tests/messaging.scm (%ngircd-os): New variable.
(run-ngircd-test): New procedure.
(%test-ngircd): New test.
* doc/guix.texi (Messaging Services): Document it.

Change-Id: I3ce9a7fd0b33afab22cf15942a1db0cf5b12bfdb
2025-04-08 10:50:17 +09:00
Maxim Cournoyer
8c43056aab
tests: Properly check the quassel service is running.
Simply calling 'start-service' without checking its return value doesn't test
much.

* gnu/tests/messaging.scm (run-quassel-test): Check service is running via
`wait-for-service'.

Change-Id: Ieb0df9aaafeb79afc11901b5aef547e0b4585bd3
2025-03-31 11:25:41 +09:00
Maxim Cournoyer
2eb22e3d0f
services: libvirt: Add UEFI firmware support.
This makes libvirt able to boot images that require a UEFI bootloader, with
the available firmwares exposed to libvirt made configurable via a new
configuration field.  For more background on the problem this fixes, see the
same issue that was reported in NixOS (see:
https://github.com/NixOS/nixpkgs/issues/115996).

* gnu/services/virtualization.scm: (list-of-file-likes?): New predicate.
(libvirt-configuration): [firmwares]: New field.
(/etc/qemu/firmware): New procedure.
(libvirt-service-type): Extend the etc-service-type with it.
(generate-libvirt-documentation): Delete obsolete procedure.
* doc/guix.texi: Re-generate doc.
* gnu/tests/virtualization.scm (run-libvirt-test): Augment memory from 256 to
512 MiB.  Test it.

Series-to: 77110@debbugs.gnu.org
Change-Id: I40694964405f13681520bf1e28b7365b0200d8f7
2025-03-27 21:21:06 +09:00
Ludovic Courtès
14f10a1f83
tests: ganeti: Increase VM memory size.
* gnu/tests/ganeti.scm (run-ganeti-test): Pass ‘-m 1024’ to
‘make-marionette’.

Reviewed-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Change-Id: I82c8a0eb37c16079f1affe793afc0d8a773c62c8
2025-03-23 19:30:32 +01:00
Ludovic Courtès
30a5ada6be
tests: ganeti: Write system log to /dev/console.
* gnu/tests/ganeti.scm (%ganeti-os): Wrap in
‘operating-system-with-console-syslog’.

Reviewed-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Change-Id: Ie86ad640ad6a7c154f5768ac4250acdd0e8940af
2025-03-23 19:30:26 +01:00
Ludovic Courtès
8de23e8260
tests: ganeti: Remove unnecessary ‘begin’.
* gnu/tests/ganeti.scm (run-ganeti-test): Remove ‘begin’ where
unnecessary.

Reviewed-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Change-Id: I3a36fffdc797c9187b5ffa406f7a06985f18d29c
2025-03-23 19:30:20 +01:00
Ludovic Courtès
caf5869a1d
tests: Make ‘operating-system-with-console-syslog’ public.
* gnu/tests/install.scm (operating-system-with-console-syslog): Move to…
* gnu/tests.scm (operating-system-with-console-syslog): … here.  New
procedure.

Reviewed-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Change-Id: I015e24525140365d09f22127d366107fdc9ca902
2025-03-23 19:30:12 +01:00
Ludovic Courtès
3511dab3f7
tests: Factorize ‘guix-daemon’ test cases.
* gnu/tests/base.scm (guix-daemon-test-cases): New procedure, with code
moved from…
(run-guix-daemon-test): … here. Use it.
* gnu/tests/foreign.scm (run-foreign-install-test): Likewise.

Change-Id: I6f2d03d30d7b7648b6eb7e77e36c3da54f80d79c
2025-03-10 15:41:34 +01:00
Ludovic Courtès
39c890cacf
tests: Factorize ‘%hello-dependencies-manifest’.
* gnu/tests/base.scm (%hello-dependencies-manifest): Export.
* gnu/tests/foreign.scm (%installation-tarball-manifest): Use it.

Change-Id: Id92232f479ab5d1f0c48036b0546e3745aa63e52
2025-03-10 15:41:33 +01:00
Ludovic Courtès
9e07d889c4
tests: Add ‘guix-daemon’ test.
* gnu/tests/base.scm (manifest-entry-without-grafts): New procedure.
(%hello-dependencies-manifest): New variable.
(run-guix-daemon-test): New procedure.
(%test-guix-daemon): New variable.

Change-Id: Ia37966de1f61fb428e6fb2244271bf389a74af6d
2025-03-10 15:41:33 +01:00
Ludovic Courtès
75e3d34295
tests: Move Avahi test to its own file.
This mirrors the (gnu services avahi) module.

* gnu/tests/base.scm (%avahi-os, run-nss-mdns-test, %test-nss-mdns):
Move to…
* gnu/tests/avahi.scm: … here.  New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.

Change-Id: I04705e57408619d948c928873c40c470aa4e949d
2025-03-10 15:41:33 +01:00
Ludovic Courtès
7e4627f9c7
tests: Move mcron test to its own file.
This mirrors the (gnu services mcron) module.

* gnu/tests/base.scm (%mcron-os, run-mcron-test, %test-mcron): Move to…
* gnu/tests/mcron.scm: … here.  New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.

Change-Id: Id2830d08d8e797e008c5fec7964fb5f6a5ea2fad
2025-03-10 15:41:33 +01:00
Ludovic Courtès
d0510dcd82
gnu: Adjust tests for ‘shepherd-system-log-service-type’.
This is a followup to 8492a3c896.

* gnu/services/virtualization.scm (%minimal-vm-syslog-config): Remove.
(%system-log-message-destination): New variable.
(%virtual-build-machine-operating-system): Use it, and modify
‘shepherd-system-log-service-type’ instead of ‘syslog-service-type’.
* gnu/tests/base.scm (%avahi-os): Likewise.
* gnu/tests/install.scm (%syslog-conf): Remove.
(operating-system-with-console-syslog): Modify
‘shepherd-system-log-service-type’ instead of ‘syslog-service-type’.
* gnu/tests/nfs.scm (%nfs-os, run-nfs-full-test): Likewise.
* gnu/tests/reconfigure.scm (run-kexec-test): Likewise.

Change-Id: I142d34ad27594a538f5b75daf087e48c690171b8
2025-03-10 00:38:05 +01:00
Sören Tempel
5ead9fa56c
services: networking: Add dhcpcd service.
This is intended as an alternative to dhcp-client-service-type as
isc-dhcp has reached its end-of-life in 2022 (three years ago!),
see #68619 for more details.  Long-term, this services is therefore
intended to replace dhcp-client-service-type.

* gnu/services/networking.scm (dhcpcd-service-type): New service.
(dhcpcd-shepherd-service): New procedure.
(dhcpcd-account-service): New variable.
(dhcpcd-config-file): New procedure.
(dhcpcd-configuration): New record type.
(dhcpcd-serialize-list-of-strings, dhcpcd-serialize-boolean)
(dhcpcd-serialize-string): New procedures.
(serialize-field-name): New procedure.
* gnu/tests/networking.scm (run-dhcpcd-test): New procedure.
(%dhcpcd-os, %test-dhcpcd): New variables.
* doc/guix.texi (Networking Services): Document it.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2025-03-08 16:09:41 +01:00
Ludovic Courtès
f57a660fc6
tests: Test installation on Debian.
* gnu/tests/foreign.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.

Change-Id: I1f24d83bdc298acbef15db2e19775cc1d3fbd56c
2025-03-05 20:34:04 +01:00
Andy Tai
38011da03d
installer: Include icewm as a desktop environment.
* gnu/installer/services.scm (%system-services): Include icewm as a desktop
environment.
* gnu/tests/install.scm (installation-target-desktop-os-for-gui-tests): Add
icewm to the list of packages.
* etc/manifests/release.scm: (%system-packages): Add icewm.

Change-Id: I881c1dd4289281e51c81d83fac785ef064e6ff6a
Signed-off-by: Christopher Baines <mail@cbaines.net>
2025-03-01 22:22:34 +00:00
Alexey Abramov via Guix-patches via
c9d9eab868
tests: dovecot: Add sieve.
* gnu/tests/mail.scm (%dovecot-os): Add dovecot-pigeonhole and simple
imapsieve configuration.
* gnu/tests/mail.scm (run-dovecot-test): Define simple sieve
script. Add SELECT TESTBOX step to let dovecot properly do mailbox
synchronization.

Change-Id: I2f21c5be66b51143ddec72eee24555ea2c40d845
Signed-off-by: Christopher Baines <mail@cbaines.net>
2025-02-25 10:57:51 +00:00
Maxim Cournoyer
bcb5724e59
tests: web: Add nginx+anonip test.
This test reproduces the problem reported in bug #59181 ("[berlin] web
services fail to start on reboot due to anonip").

* gnu/tests/web.scm (run-webserver-test) <extra-args>: New keyword argument.
(%nginx+anonip-os, nginx-anonip-tests, %test-nginx+anonip): New variables.

Change-Id: I7bbc8fb9f2ab33ce89bf1c0945d7ddbddf26a7ea
2025-02-13 00:07:21 +09:00
Maxim Cournoyer
a595a52b7b
tests: Add anonip system test.
* gnu/tests/web.scm (%test-anonip): New test.
(%anonip-os): New variables.
(run-anonip-test): New procedure.

Change-Id: Ieed210a784dbdeee8a498e74b6c0e31cb72cd9b8
2025-02-13 00:07:21 +09:00
Maxim Cournoyer
df568fc411
tests: web: Have the retry-on-error throw on exhausted attempts.
Previously, it'd simply return the error arguments, which would not always
fail a 'test-assert' test, for example.

* gnu/tests/web.scm (retry-on-error): Re-throw the error when the attempts
have been exhausted.

Change-Id: Ic1468d8ba23f0f78377e90d19bccb2878dc56f0e
2025-02-13 00:07:21 +09:00
muradm
ee0d1b144c
services: greetd: Improve greeter configurations.
This improvement focuses on providing common user session scripts
for use by multiple greeters. Now user session entry point is
factored out into '<greetd-user-session>', which can be reused
as is with different greeters. By default it uses 'bash' as
first user process. Then user normally starts additional programs
with '.profile' or '.bashrc'. Using 'command', 'command-args' and
'extra-env' one can specify something else, which could be
'dbus-session' wrapped process, some desktop environment or else.
While the above is possible, one is still encouraged to use
'.bashrc', '.profile' or similar.

It also fixes incorrect use of 'XDG_RUNTIME_DIR' for 'wlgreet'.
'wlgreet' requires a compositor to run. We provide common sway based
greeter script, which can be shared by other graphical greeters.

* gnu/services/base.scm (<greetd-user-session>): Common user session
factored out, for shared use by multiple greeters.
(<greetd-agreety-session>): Switch to common user session.
(<greetd-wlgreet-configuration>): Refactor 'wlgreet' configuration.
(<greetd-wlgreet-sway-session>): Switch to common user session.
(<greetd-terminal-configuration>): Add 'extra-shepherd-requirement'
for establishing configurable Shepherd service dependency.
* gnu/tests/desktop.scm (%minimal-services): Reflect configuration
changes.
* doc/guix.texi (Base Services): Document refactoring changes.

Change-Id: I9d45a592b355eb9c438be5b1d4d15555ce4956fa
Modified-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Signed-off-by: Maxim Cournoyer <maxim.cournoyer@gmail.com>
2025-02-06 22:26:45 +09:00
muradm
bc6769f121
tests: minimal-desktop: Adjust to greetd 0.10.3.
This is a followup to 55cead2c49.

* gnu/tests/desktop.scm (run-minimal-desktop-test): Do not check for
‘GREETD_SOCK’.

Change-Id: I2eb5af947ee1753d6237c95feb3cea7ed98f90ad
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2025-01-20 00:25:47 +01:00
Giacomo Leidi
24a12aeb91
services: rootless-podman: Enable I/O delegation.
Based on
https://rootlesscontaine.rs/getting-started/common/cgroup2/#enabling-cpu-cpuset-and-io-delegation
, this patch enables I/O delegation for cgroups v2 enabled users.

* gnu/services/containers.scm (cgroups-limits-entrypoint): Enable I/O
controller delegation.
* gnu/tests/containers.scm: Test it.

Change-Id: I7caba33695f11830bea477c4ab3afb89cfaa2fa5
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2025-01-11 23:36:58 +01:00
Giacomo Leidi
b7746ad83f
services: tests: Add delay for rootless Podman system test.
* gnu/tests/containers.scm (run-rootless-podman-test): Add 60 seconds
long delay before tests are actually run.

Change-Id: Ifcf70f7258f9e0886bf829884d7daedc9803352b
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2025-01-11 23:36:58 +01:00
Sören Tempel
8db6cfe022
services: dns: Add unbound service.
This allows using Unbound as a local DNSSEC-enabled resolver. This
commit also allows configuration of the Unbound DNS resolver via a
Scheme API. The API currently provides very common options and
includes an escape hatch to enable less common configurations.

* gnu/service/dns.scm (unbound-serialize-field): New procedure.
(unbound-serialize-alist, unbound-serialize-section)
(unbound-serialize-string, unbound-serialize-boolean)
(unbound-serialize-list-of-strings): New procedures.
(unbound-zone): New record type.
(unbound-serialize-unbound-zone)
(unbound-serialize-list-of-unbound-zone): New procedures.
(unbound-remote): New record type.
(unbound-serialize-unbound-remote): New procedure.
(unbound-server): New record type.
(unbound-serialize-unbound-server): New procedure.
(unbound-configuration): New record type.
(unbound-config-file, unbound-shepherd-service): New procedures.
(unbound-account-service): New variable.
(unbound-service-type): New services.
* gnu/tests/dns.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
* doc/guix.texi (DNS Services): Document it.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Change-Id: I4c9646c9e17d4882e596d33ff8f738e1877fa1ae
2025-01-11 23:36:58 +01:00
Ludovic Courtès
431ab10344
services: static-networking: Fail when devices don’t show up.
Fixes <https://issues.guix.gnu.org/71173>.

* gnu/services/base.scm (network-set-up/linux): Define
‘max-set-up-duration’ and use it.
* gnu/tests/networking.scm (%static-networking-with-nonexistent-device):
New variable.
(run-static-networking-failure-test): New procedure.
(%test-static-networking-failure): New variable.

Change-Id: Idba9b36750aa8c6368c8f6d1bc1358066f7432e4
2025-01-08 22:54:37 +01:00
Leo Famulari
1dcd0ded86
gnu: Add linux-libre-6.12.
* gnu/packages/linux.scm (linux-libre-6.12-version,
linux-libre-6.12-gnu-revision, deblob-scripts-6.12,
linux-libre-6.12-pristine-source, linux-libre-6.12-source,
linux-libre-headers-6.12, linux-libre-6.12): New variables.
(linux-libre-headers-latest): Use linux-libre-headers-6.12.
(linux-libre-lts-version, linux-libre-lts-gnu-revision,
linux-libre-lts-pristine-source, linux-libre-lts-source, linux-libre-lts): Use
linux-libre 6.12.
* gnu/tests/base.scm (%test-linux-libre-6.12): New test.
* gnu/packages/aux-files/linux-libre/6.12-arm.conf,
gnu/packages/aux-files/linux-libre/6.12-arm64.conf,
gnu/packages/aux-files/linux-libre/6.12-i686.conf,
gnu/packages/aux-files/linux-libre/6.12-x86_64.conf,
gnu/packages/aux-files/linux-libre/6.12-riscv.conf: New files.
* Makefile.am (AUX_FILES): Add them.

Change-Id: I430d9dd29cda4bd4b66ad6eddc004935f93bb111
2025-01-07 18:13:45 -05:00
Leo Famulari
92bfa12254
tests: Add tests for all the longterm-support kernels.
* gnu/tests/base.scm (%test-linux-libre-6.6, %test-linux-libre-6.1): New tests.

Change-Id: Ica31ae263348c38ac21efeb65d9a245e1a877268
2025-01-07 18:13:45 -05:00
Leo Famulari
7b40b9d2d2
gnu: Remove linux-libre 4.19.
This kernel series is no longer supported upstream.

* gnu/packages/linux.scm (linux-libre-4.19-version,
linux-libre-4.19-gnu-revision, deblob-scripts-4.19,
linux-libre-4.19-pristine-source, linux-libre-4.19-source,
linux-libre-headers-4.19, linux-libre-4.19, linux-libre-arm-generic-4.19,
linux-libre-arm-omap2plus-4.19): Remove variables.
* gnu/tests/base.scm (%test-linux-libre-4.19): Remove variable.
* gnu/packages/aux-files/linux-libre/4.19-arm.conf,
gnu/packages/aux-files/linux-libre/4.19-arm64.conf,
gnu/packages/aux-files/linux-libre/4.19-i686.conf,
gnu/packages/aux-files/linux-libre/4.19-x86_64.conf: Delete files.
* Makefile.am (AUX_FILES): Remove them.

Change-Id: If79ccbb948975c544b27757104d360539970377c
2025-01-04 12:19:36 -05:00