Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion pkgs/by-name/ma/matrix-tuwunel/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,8 @@ rustPlatform.buildRustPackage (finalAttrs: {
libredirect.hook
];

# Make sure tuwunel doesn't try to write to arbitrary
# directories or have DNS timeouts during `cargo test`.
preCheck =
let
fakeResolvConf = writeTextFile {
Expand All @@ -165,7 +167,16 @@ rustPlatform.buildRustPackage (finalAttrs: {
export NIX_REDIRECTS="/etc/resolv.conf=${fakeResolvConf}"
export TUWUNEL_DATABASE_PATH="$(mktemp -d)/smoketest.db"
'';
doCheck = true;

# For some unexplained reason, tuwunel's built-in tests
# time out on aarch64 when run on Hydra. The tests run
# without issue on x86-64 on Hydra and they also run fine
# on aarch64 on at least one dev's machine.
doCheck =
!(lib.elem stdenv.hostPlatform.system [
"aarch64-linux"
"aarch64-darwin"
]);

passthru = {
rocksdb = rocksdb'; # make used rocksdb version available (e.g., for backup scripts)
Expand Down
Loading