mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-29 17:14:33 +00:00
63 lines
1.8 KiB
Nix
63 lines
1.8 KiB
Nix
{ lib, buildGoModule, fetchFromGitHub
|
|
, nixosTests, postgresql, postgresqlTestHook }:
|
|
|
|
buildGoModule rec {
|
|
pname = "matrix-dendrite";
|
|
version = "0.11.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "matrix-org";
|
|
repo = "dendrite";
|
|
rev = "v${version}";
|
|
sha256 = "sha256-EJUHpV+ZsMMSMsJGhF0Atblksg5rgI3a2qcRxLyZP38=";
|
|
};
|
|
|
|
vendorHash = "sha256-Ygd5wC4j0kAbEMMVct5WXZvkcYSqqK8d7ZZ9CDU1RHU=";
|
|
|
|
subPackages = [
|
|
# The server as a monolith: https://matrix-org.github.io/dendrite/installation/install/monolith
|
|
"cmd/dendrite-monolith-server"
|
|
# The server as a polylith: https://matrix-org.github.io/dendrite/installation/install/polylith
|
|
"cmd/dendrite-polylith-multi"
|
|
# admin tools
|
|
"cmd/create-account"
|
|
"cmd/generate-config"
|
|
"cmd/generate-keys"
|
|
"cmd/resolve-state"
|
|
## curl, but for federation requests, only useful for developers
|
|
# "cmd/furl"
|
|
## an internal tool for upgrading ci tests, only relevant for developers
|
|
# "cmd/dendrite-upgrade-tests"
|
|
## tech demos
|
|
# "cmd/dendrite-demo-pinecone"
|
|
# "cmd/dendrite-demo-yggdrasil"
|
|
# "cmd/dendritejs-pinecone"
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
postgresqlTestHook
|
|
postgresql
|
|
];
|
|
|
|
postgresqlTestUserOptions = "LOGIN SUPERUSER";
|
|
preCheck = ''
|
|
export PGUSER=$(whoami)
|
|
# temporarily disable this failing test
|
|
# it passes in upstream CI and requires further investigation
|
|
rm roomserver/internal/input/input_test.go
|
|
'';
|
|
|
|
passthru.tests = {
|
|
inherit (nixosTests) dendrite;
|
|
};
|
|
|
|
meta = with lib; {
|
|
homepage = "https://matrix-org.github.io/dendrite";
|
|
description = "A second-generation Matrix homeserver written in Go";
|
|
changelog = "https://github.com/matrix-org/dendrite/releases/tag/v${version}";
|
|
license = licenses.asl20;
|
|
maintainers = teams.matrix.members;
|
|
platforms = platforms.unix;
|
|
};
|
|
}
|