stalwart-mail: 0.10.7 -> 0.11.5; stalwart-mail.webadmin: 0.1.20 -> 0.1.24 (#377252)
This commit is contained in:
@@ -92,19 +92,21 @@ in
|
||||
resolver.public-suffix = lib.mkDefault [
|
||||
"file://${pkgs.publicsuffix-list}/share/publicsuffix/public_suffix_list.dat"
|
||||
];
|
||||
config.resource =
|
||||
let
|
||||
hasHttpListener = builtins.any (listener: listener.protocol == "http") (
|
||||
lib.attrValues cfg.settings.server.listener
|
||||
);
|
||||
in
|
||||
{
|
||||
spam-filter = lib.mkDefault "file://${cfg.package}/etc/stalwart/spamfilter.toml";
|
||||
}
|
||||
// lib.optionalAttrs ((builtins.hasAttr "listener" cfg.settings.server) && hasHttpListener) {
|
||||
webadmin = lib.mkDefault "file://${cfg.package.webadmin}/webadmin.zip";
|
||||
};
|
||||
webadmin.path = "/var/cache/stalwart-mail";
|
||||
config = {
|
||||
spam-filter.resource = lib.mkDefault "file://${cfg.package}/etc/stalwart/spamfilter.toml";
|
||||
webadmin =
|
||||
let
|
||||
hasHttpListener = builtins.any (listener: listener.protocol == "http") (
|
||||
lib.attrValues cfg.settings.server.listener
|
||||
);
|
||||
in
|
||||
{
|
||||
path = "/var/cache/stalwart-mail";
|
||||
}
|
||||
// lib.optionalAttrs ((builtins.hasAttr "listener" cfg.settings.server) && hasHttpListener) {
|
||||
resource = lib.mkDefault "file://${cfg.package.webadmin}/webadmin.zip";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# This service stores a potentially large amount of data.
|
||||
|
||||
@@ -5,24 +5,26 @@
|
||||
stalwart-mail,
|
||||
}:
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
rustPlatform.buildRustPackage {
|
||||
inherit (stalwart-mail) src version cargoDeps;
|
||||
pname = "stalwart-cli";
|
||||
version = stalwart-mail.version;
|
||||
src = stalwart-mail.src;
|
||||
|
||||
buildAndTestSubdir = "crates/cli";
|
||||
useFetchCargoVendor = true;
|
||||
cargoHash = "sha256-k0pNNLwFRLI7eHjVwHGjgrnX4moWOwoWvMiyPfGMgCo=";
|
||||
cargoBuildFlags = [
|
||||
"--package"
|
||||
"stalwart-cli"
|
||||
];
|
||||
cargoTestFlags = [
|
||||
"--package"
|
||||
"stalwart-cli"
|
||||
];
|
||||
|
||||
doInstallCheck = true;
|
||||
nativeInstallCheckInputs = [ versionCheckHook ];
|
||||
versionCheckProgramArg = [ "--version" ];
|
||||
|
||||
meta = {
|
||||
inherit (stalwart-mail.meta) license homepage changelog;
|
||||
description = "Stalwart Mail Server CLI";
|
||||
homepage = "https://github.com/stalwartlabs/mail-server";
|
||||
changelog = "https://github.com/stalwartlabs/mail-server/blob/v${version}/CHANGELOG.md";
|
||||
license = lib.licenses.agpl3Only;
|
||||
mainProgram = "stalwart-cli";
|
||||
maintainers = with lib.maintainers; [
|
||||
giomf
|
||||
|
||||
@@ -13,34 +13,24 @@
|
||||
darwin,
|
||||
nix-update-script,
|
||||
nixosTests,
|
||||
rocksdb_8_11,
|
||||
rocksdb,
|
||||
callPackage,
|
||||
}:
|
||||
|
||||
let
|
||||
# Stalwart depends on rocksdb crate:
|
||||
# https://github.com/stalwartlabs/mail-server/blob/v0.8.0/crates/store/Cargo.toml#L10
|
||||
# which expects a specific rocksdb versions:
|
||||
# https://github.com/rust-rocksdb/rust-rocksdb/blob/v0.22.0/librocksdb-sys/Cargo.toml#L3
|
||||
# See upstream issue for rocksdb 9.X support
|
||||
# https://github.com/stalwartlabs/mail-server/issues/407
|
||||
rocksdb = rocksdb_8_11;
|
||||
version = "0.10.7";
|
||||
in
|
||||
rustPlatform.buildRustPackage {
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "stalwart-mail";
|
||||
inherit version;
|
||||
version = "0.11.6";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "stalwartlabs";
|
||||
repo = "mail-server";
|
||||
tag = "v${version}";
|
||||
hash = "sha256-BATkLgfkz94u2M+Xy6PYQi+7EIxBe86VLYTnBI8PzzY=";
|
||||
hash = "sha256-8xRmAPqIVanGyWoUWb4DyRkhl5djPJD+ie03B3FyZ4w=";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
useFetchCargoVendor = true;
|
||||
cargoHash = "sha256-k0pNNLwFRLI7eHjVwHGjgrnX4moWOwoWvMiyPfGMgCo=";
|
||||
cargoHash = "sha256-PHr73GQ/6d5ulJzntSHIilGzdF4Y8Np9jSFa6F2Nwao=";
|
||||
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
@@ -83,8 +73,6 @@ rustPlatform.buildRustPackage {
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $out/etc/stalwart
|
||||
cp resources/config/spamfilter.toml $out/etc/stalwart/spamfilter.toml
|
||||
cp -r resources/config/spamfilter $out/etc/stalwart/
|
||||
|
||||
mkdir -p $out/lib/systemd/system
|
||||
|
||||
@@ -98,8 +86,10 @@ rustPlatform.buildRustPackage {
|
||||
"--skip=directory::internal::internal_directory"
|
||||
"--skip=directory::ldap::ldap_directory"
|
||||
"--skip=directory::sql::sql_directory"
|
||||
"--skip=directory::oidc::oidc_directory"
|
||||
"--skip=store::blob::blob_tests"
|
||||
"--skip=store::lookup::lookup_tests"
|
||||
"--skip=smtp::lookup::sql::lookup_sql"
|
||||
# thread 'directory::smtp::lmtp_directory' panicked at tests/src/store/mod.rs:122:44:
|
||||
# called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }
|
||||
"--skip=directory::smtp::lmtp_directory"
|
||||
|
||||
@@ -16,13 +16,13 @@
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "webadmin";
|
||||
version = "0.1.20";
|
||||
version = "0.1.24";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "stalwartlabs";
|
||||
repo = "webadmin";
|
||||
tag = "v${version}";
|
||||
hash = "sha256-0/XiYFQDqcpRS9DXPyKQwoifnEd2YxFiyDbV12zd2RU=";
|
||||
hash = "sha256-KtCSP7PP1LBTcP1LFdEmom/4G8or87oA6ml6MXOhATk=";
|
||||
};
|
||||
|
||||
npmDeps = fetchNpmDeps {
|
||||
@@ -32,7 +32,7 @@ rustPlatform.buildRustPackage rec {
|
||||
};
|
||||
|
||||
useFetchCargoVendor = true;
|
||||
cargoHash = "sha256-rXpyPLe28YgUkDJNBEA0HGSpmcHOik9em1uwLuYAU8I=";
|
||||
cargoHash = "sha256-VXbFQLMtqypQlisirKhlfu9PYgmEryJx85GRqlRslNY=";
|
||||
|
||||
postPatch = ''
|
||||
# Using local tailwindcss for compilation
|
||||
|
||||
Reference in New Issue
Block a user