Files
nixpkgs/nixos/tests/nextcloud/home-mount.nix
Maximilian Bosch ef3a9736aa nixos/nextcloud: add test verifying that bind-mounts and special places of /var/lib/nextcloud are OK
This is a regular source for confusion and had no test-coverage so far,
so adding two tests that

* Make sure Nextcloud running in a different location (tmpfs mount here as mock for the mount
  of a different disk).

* A bind-mount of Nextcloud from a disk-mount to /var/lib/nextcloud can
  be created.
2026-08-02 19:07:28 +02:00

33 lines
633 B
Nix

{
name,
pkgs,
testBase,
system,
...
}:
with import ../../lib/testing-python.nix { inherit system pkgs; };
runTest (
{ config, lib, ... }:
{
inherit name;
meta.maintainers = lib.teams.nextcloud.members;
imports = [ testBase ];
nodes.nextcloud = { pkgs, ... }: {
system.activationScripts.nc-mock-mount = {
deps = [ "users" ];
text = ''
${pkgs.coreutils}/bin/mkdir -p /mnt
${pkgs.util-linux}/bin/mount -t tmpfs tmpfs /mnt
'';
};
services.nextcloud = {
config.dbtype = "sqlite";
home = "/mnt/nextcloud";
};
};
}
)