isc-dhcp has been unmaintained since 2022. This is a follow-up to commit
3e713ae41c.
* doc/guix.texi (Keyboard Layout and Networking and Partitioning): Adjust
example.
* etc/manifests/cross-compile.scm (%system-packages)
* etc/manifests/release-desktop.scm (%desktop-packages)
* etc/manifests/release-minimal.scm (%system-packages): Replace "isc-dhcp"
with "dhcpcd".
* gnu/system.scm (%base-packages-networking): Likewise.
* gnu/tests/install.scm (%simple-installation-script)
(%extlinux-gpt-installation-script)
(%simple-installation-script-for-/dev/vda)
(%separate-store-installation-script)
(%extra-encrypted-packages): Likewise.
Until now these variables were not exported and thus the corresponding tests
were not run by ‘make check’ nor by continuous integration.
* gnu/tests/base.scm: (%test-linux-libre-6.12, %test-linux-libre-6.6, %test-linux-libre-6.1):
Export.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Merges: #10642
The socket position changed from /var/run to /run
in libtirpc 1.3.7, commit 2f9ce0ca4e0e21f5286e75fab32202f3913d9725
("Move rpcbind.sock to /run").
* gnu/tests/nfs.scm (%test-nfs): Change rpcbind socket to /run.
Merges: https://codeberg.org/guix/guix/pulls/10487
Reviewed-by: Sharlatan Hellseher <sharlatanus@gmail.com>
Signed-off-by: Nguyễn Gia Phong <cnx@loang.net>
* gnu/services/version-control.scm
(git-http-nginx-location-configuration): Handle the case
where uri-path is "/" by not adding an extra slash prefix.
* gnu/tests/version-control.scm (git-nginx-root-configuration):
Generalize from %git-nginx-root-configuration
to take uri-path as an argument from...
(git-http-os): ...this new procedure generalized from %git-http-os
to take uri-path as an argument from...
(git-http-test): ...this new procedure generalized
from run-git-http-test to return a system test
instead of just its store value. Additionally
take name, description, and uri-path arguments.
(%test-git-http): Adjust accordingly.
(%test-git-http-root-path): Duplicate %test-git-http
with "/" instead of "/git/" as uri-path.
Merges: https://codeberg.org/guix/guix/pulls/6140
Co-authored-by: Nguyễn Gia Phong <cnx@loang.net>
Signed-off-by: Nguyễn Gia Phong <cnx@loang.net>
Update RabbitMQ default configuration to use localhost interface by
default and avoid listening on public interfaces.
Change the default configuration file to set inter-node communication
listener to localhost network interface (see also
https://www.rabbitmq.com/docs/networking#distribution). This requires
setting RabbitMQ node name to `rabbit@localhost`, so introduce
`node-name` RabbitMQ configuration field with such default value.
Path to the RabbitMQ environment configuration file was hardcoded.
Remove the hardcoding and allow to create such file with env-config-file
RabbitMQ configuration field.
Add new RabbitMQ service tests to check RabbitMQ broker startup and
status after the service is started.
* gnu/services/high-availability.scm (<rabbitmq-configuration>)
[<node-name>, <env-config-file>]: New fields.
(rabbitmq-shepherd-service): Use them.
(%default-rabbitmq-config-file): Update.
* gnu/tests/high-availability.scm (run-rabbitmq-test): Add new tests.
* doc/gnu.texi (High Availability Services): Document new fields and
provide information about local interfaces.
Merges: guix/guix!9360
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
Apply the same workaround that runc, crun, and buildah apply
unconditionally: immediately after entering the new mount namespace,
remount / recursively as MS_PRIVATE. Concretely, the call we will
make in Guile mirrors the verbatim C call already present in crun at
https://github.com/containers/crun/blob/99a8512ef50c5af1b8cfff28eacddf870220ca9f/src/libcrun/linux.c#L4677:
ret = mount (NULL, "/", NULL, MS_REC | MS_PRIVATE, NULL);
and the Go equivalents in:
- runc (defaults to MS_SLAVE for reasons documented in its pivotRoot):
https://github.com/opencontainers/runc/blob/a7e766484c38be1f0cf9b7d960c9324316cb7204/libcontainer/rootfs_linux.go#L1106
- buildah (expands to mount("", "/", "none", MS_REC|MS_PRIVATE, "")):
https://github.com/podman-container-tools/buildah/blob/769d311d739dd4bbde496a9480879ce6aadaa1e0/bind/mount.go#L41
Our implementation:
1. Detaches the container's mount namespace from the host's propagation
peer group, so subsequent mount/umount events inside the container
do not propagate to the host.
2. Makes the kernel's pivot_root(2) preconditions satisfied: both
new_root (the tmpfs we then create) and its parent (/) have propagation
type MS_PRIVATE.
3. Should have no effect on processes outside the new mount namespace. The
host's / retains whatever propagation type it had.
mount-file-systems is only invoked from run-container when both
'mnt namespace is requested and root != "/", so we are
guaranteed to be inside a fresh mount namespace at this point and that
the remount only affects this namespace. The remount must happen before
the tmpfs is created. Once the tmpfs exists as a child of the (shared)
host /, fixing only the host / does not retroactively change the
propagation type the tmpfs already inherited. Doing the remount first
means every subsequent mount this function performs inherits MS_PRIVATE
from its parent.
* guix/build/syscalls.scm (MS_PRIVATE): New variable.
* gnu/build/linux-container.scm (mount-file-systems): Remount / recursively as MS_PRIVATE, immediately after entering the new mount namespace.
* gnu/services/containers.scm (%miniflux-create-admin-credentials,
%rootless-podman-os-with-least-authority-wrapper,
run-rootless-podman-test-with-least-authority-wrapper): New bindings.
(%test-rootless-podman-with-least-authority-wrapper): New regression
test making sure the rootless-podman-service-type does not break again
least-authority-wrapper bases services.
Fixes: https://codeberg.org/guix/guix/issues/3233
Merges: https://codeberg.org/guix/guix/pulls/9140
The motivation is twofold:
1. We can ensure the presence of the nginx default configuration fragments in
the configuration file directory;
2. 'herd reload nginx' can now be used to reload an updated configuration
file.
Before this change, 'include fastcgi_params;', for example, would fail with
error:
nginx: [emerg] open() "/gnu/store/fastcgi_params" failed
(2: No such file or directory) in /gnu/store/...-nginx.conf:50
* gnu/services/web.scm (%nginx-configuration-file): New variable.
(nginx-activation): Delay configuration file check to...
(nginx-shepherd-service): ... a new one-shot 'nginx-init' service. Adjust to
use the %nginx-configuration-file variable for the configuration file.
<actions>: Add a new 'configuration' action.
(nginx-conf-files, nginx-etc-directory): New procedures.
(nginx-service-type): Extend etc-service-type with nginx-service-type.
* gnu/tests/web.scm (%nginx-servers): Add an include directive to test config
to ensure it now works.
Merges: !8811
Change-Id: I26882ab01288ec4dd374e9f282e95ffa33dfa3cc
* gnu/tests/networking.scm (run-network-manager-test): New variable.
(run-network-manager-dnsmasq-test): New variable.
Change-Id: I8f957e11ba27ed15fe8d6136b934e0dd8b92a4d6
Signed-off-by: Liliana Marie Prikler <liliana.prikler@gmail.com>
* gnu/tests/web.scm (%gunicorn-os): New variable.
(run-gunicorn-test): New variable.
(%test-gunicorn): New variable.
Change-Id: I1ee3fd4c29c7c44aa9c271c6775f953790ca60c3
The memory requirements seem to have increased, the test now consistently
fails with 1.2 GB.
Change-Id: I766cbe75fa6f09e513157f6f9e954dd2502d8c7a
Signed-off-by: Rutherther <rutherther@ditigal.xyz>
Merges: #6248
The desktop install tests are currently failing due to lack of packages in
their store. These packages have been added in b01968f654.
* gnu/tests/install.scm
(%extra-packages): Renamed to %extra-encrypted-packages.
(%extra-encrypted-packages): New variable.
(%extra-desktop-packages): New variable.
(%extra-mandb-packages): New variable.
(installation-os-for-gui-tests): Use them in packages.
Change-Id: Ib49fd65651e94bfd05215773eef5046064d7815a
Signed-off-by: Rutherther <rutherther@ditigal.xyz>
* gnu/tests/databases.scm (%timescaledb-os)[services]<postgresql>:
Use the postgresql package from timescaledb's inputs.
(run-timescaledb-test): Use the psql binary installed in the profile.
Change-Id: Ib9a0efd3534f2f0731e3d58ac4f8f59301fc8592
* gnu/services/web.scm (sogogi-service-type): New services.
(sogogi-serialize-section, sogogi-serialize-field)
(sogogi-serialize-string, sogogi-serialize-list-of-strings)
(sogogi-serialize-sogogi-user, sogogi-serialize-sogogi-location)
(sogogi-serialize-list-of-sogogi-user): New procedures.
(sogogi-user, sogogi-location)
(sogogi-configuration): New record types.
(sogogi-account-service): New variable.
(sogogi-config-file, sogogi-shepherd-service): New procedures.
* gnu/tests/web.scm (%test-sogogi): Add tests for the service.
* doc/guix.texi (Web Services): Document it.
Change-Id: I5cc6dd84d6c7c8d5d13b685853b19c5d433ed7e5
* gnu/services/messaging.scm (%default-soju-shepherd-requirement): New
variable.
(soju-ssl-certificate): New configuration record.
(soju-database): New configuration record.
(soju-configuration): New configuration record.
(serialize-soju-configuration,soju-activation,soju-accounts,
soju-shepherd-services): New procedures.
(soju-service-type): New service.
(serialize-ngircd-configuration): Reformat.
(pounce-configuration): Reformat.
* doc/guix.texi: Document the new soju service.
* gnu/tests/messaging.scm: Test the new soju service.
Change-Id: I6223ecac1aaaab76bd75461851ffe4cec0678118
* gnu/services/virtualization.scm (%libvirt-activation): Activate
default libvirt network configuration file.
* gnu/tests/virtualization.scm (run-libvirt-test): Drop network
definition test and replace it with a test checking that the default
network is inactive by default.
Change-Id: I03b6314a390c6d93ebf886d7033867ff5cacad74
This patch is supposed to introduce a test case to ensure use cases like
the one of https://codeberg.org/guix/guix/issues/3818 are working.
* gnu/tests/containers.scm (%guile-oci-image): New variable.
(%guile-bash-oci-image): New variable.
(%oci-rootless-podman-os)[fist-container]: Use %guile-oci-image.
[second-container]: Use file-like object as oci-image value.
(%oci-docker-os): Ditto.
Change-Id: I0052243dba2d901d497e1c0976a5aa1ebe9864a0
Reviewed-by: Owen T. Heisler <writer@owenh.net>
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
When a device with a UUID is missing, canonicalize-device-spec will throw an
error. This error is not handled for mount-may-fail? devices. That means
that if you use UUID device and it isn't available, the boot will hang on
the user-file-systems not being started. All user services depend on that
service.
Also added a test for this behavior.
* gnu/build/file-systems.scm
(mount-file-system): Guard canonicalize-device-spec call.
(canonicalize-device-spec): Throw &partition-lookup-error on missing
partition.
(&partition-lookup-error): New variable.
* gnu/tests/base.scm (%test-missing-file-system): New variable.
Change-Id: I3b8d652251cef421cff6d2fdafb8d9d7d1fc74b5
Reported-By: renbus, on IRC
Signed-off-by: Maxim Cournoyer <maxim@guixotic.coop>
* gnu/services/upnp.scm (%readymedia-default-pid-directory): New variable.
(%readymedia-pid-file): New procedure.
(readymedia-shepherd-service)[start]: Start with the pid file.
(readymedia-activation): Create the pid directory.
* gnu/tests/upnp.scm (run-readymedia-test): Test the pid directory and file.
Merges: https://codeberg.org/guix/guix/pulls/1007
Change-Id: I454a89d25afe0e9bb0414645b1e4594afdf89058
Signed-off-by: Giacomo Leidi <therewasa@fishinthecalculator.me>
* gnu/services/upnp.scm (%readymedia-default-log-directory): Remove variable.
(%readymedia-default-log-file): New procedure.
(%readymedia-default-cache-directory): Turn it into a procedure.
(<readymedia-configuration>)[log-directory]: Remove field.
[log-file]: New field.
[cache-directory]: Set to %readymedia-default-cache-directory.
(readymedia-configuration->config-file): Remove "user" and "log_dir" fields.
(readymedia-shepherd-service)[modules]: Add (shepherd support).
[start]: Do not map the log-directory. For home services, do not wrap the
program with least-authority-wrapper.
(readymedia-activation): Do not create the log-directory.
* gnu/home/services/upnp.scm (%readymedia-cache-file, %readymedia-cache-path,
%readymedia-log-path): Remove variables.
(run-readymedia-test): Use the procedures properly. Do not test the
log directory. Test the log file.
* doc/guix.texi (Miscellaneous Services)[DLNA/UPnP Services]: Update doc.
Change-Id: I97d84b5287c374ddb26a495f20a36f986b0c142d
Signed-off-by: Giacomo Leidi <therewasa@fishinthecalculator.me>
* gnu/services/web.scm (go-webdav-service-type): New service.
(go-webdav-account-service): New variable.
(go-webdav-shepherd-service): New procedures.
* gnu/tests/web.scm (%test-go-webdav): Add tests for the service.
* doc/guix.texi (Web Services): Document it.
Signed-off-by: Danny Milosavljevic <dannym@friendly-machines.com>
The default timezone is set to Europe/Zaghreb, however the new check
introduced in 0a9eb3f3e2 was checking for the
one in the operating-system definition, which is Europe/Paris.
* gnu/tests/install.scm (gui-test-program): Explicitely set timezone to
Europe/Paris.
Change-Id: I7b5d327f13760632c9fbc0c1223a6a9bbc624f4d
Signed-off-by: Rutherther <rutherther@ditigal.xyz>
Merges: #4977
* gnu/tests/mail.scm
(%radicale-os): New variable.
(run-radicale-test): New function with basic tests.
(%test-radicale): New variable.
Change-Id: I4a4e093ca7ac2a20a575bcf38b6ff763edf67652
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Merges: #5361
Before this, the test failed because Avahi CLI utilities
exit with a non-zero status in case of a cache miss
(instead of blocking?).
* gnu/tests/avahi.scm (run-nss-mdns-test): Move the Avahi CLI tests
after other name resolution tests.
Change-Id: I88ab03abf39cf24ee2ce763c719444ac65504cc2
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Merges: #4955
* gnu/services/opensnitch.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add reference to it.
* doc/guix.texi (Miscellaneous Services, Security): Document it.
* gnu/tests/security.scm (%test-opensnitch): New variable.
Change-Id: I63d1b6636b3aaecf399664ec97383d82ff1391d1
* gnu/tests/foreign.scm (qcow-image-with-marionette):
- Create .autorelabel file to make copied Guile work
on SELinux-enabled systems.
(resize-lvm-xfs-partition): New variable.
(run-foreign-install-test): Increase RAM for VM to 1024
as 512 is not sufficient to run Guix installation
on Fedora.
(fedora-qcow2): New variable.
(%test-fedora-install): New variable.
Change-Id: Ib247a174dfea8630d830763410391077516a8c16
Merges: #5007
This one is a bit more complicated than the other ones, because the qcow2
image is too small to hold the tarball contents. So I have decided to add in
logic to resize the qemu img, the partition and the filesystem.
* gnu/tests/foreign.scm
(ubuntu-qcow2): New variable.
(ubuntu-uidmap-deb-file): New variable.
(ubuntu-libsuid4-deb-file): New variable.
(%test-ubuntu-install): New variable.
Change-Id: Ib705cfe0aeab5e6ede284b8eff06483aea617349e
Signed-off-by: Rutherther <rutherther@ditigal.xyz>
Merges: #4997
Change-Id: I17472d160665fa4965d1c1ee00d671746bd5fb74
* gnu/tests/foreign.scm
(qcow-image-with-marionette): Add resize-image and
resize-proc to resize the image, the partition and the file system.
(resize-ext4-partition): New variable.
(run-foreign-install-test): Add resize-image and resize-proc; Pass them to
qcow-image-with-marionette.
Change-Id: I92dbe0cdcafb5ff0a0b6c3e9b96205b4ad9d10e8
Signed-off-by: Rutherther <rutherther@ditigal.xyz>
Partly fixes guix/guix#4269.
Fixes a bug whereby shepherd (PID 1) could retain memory mappings for
/var/run/nscd/dbXXX, which are created by glibc’s NSS from database file
descriptors sent by nscd. Those mappings could then prevent
‘root-file-system’ from re-mounting the root file system as read-write.
This change causes PID 1 to drop these mappings.
PID 1 typically calls libc database functions such as ‘getgr’ when dealing
with AF_UNIX endpoints for socket-activated services, to look up the socket’s
owner and group. This is where the bug would manifest.
The regression may have been introduced by
85ac164c41, which caused nscd to handle the
password and group databases.
* gnu/services/base.scm (nscd-shepherd-service): In ‘stop’ procedure, call
‘getpw’, ‘getgr’, and ‘getaddrinfo’.
* gnu/tests/base.scm (run-root-unmount-test) <"open libc NSS database">: New
test.
(%test-root-unmount): Add #:imported-modules.
Change-Id: I197cc8c82165c631f857415898137412ce9bd439
Reported-by: Rutherther <rutherther@ditigal.xyz>
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Merges: #4828