electrs: Remove electrs user from "bitcoinrpc" and "bitcoin" sometimes

Electrs does not need to be a part of "bitcoinrpc" group because preStart
electrs.toml creation is handled by PermissionsStartOnly. "bitcoin"
group membership is only necessary when cfg.high-memory is enabled and
electrs reads blocks directly from the blocks directory.
This commit is contained in:
nixbitcoin 2020-05-03 10:30:21 +02:00
parent 7cfae66db4
commit 393ab0fb3c
No known key found for this signature in database
GPG Key ID: DD11F9AD5308B3BA

View File

@ -106,7 +106,7 @@ in {
users.users.${cfg.user} = {
description = "electrs User";
group = cfg.group;
extraGroups = [ "bitcoinrpc" "bitcoin"];
extraGroups = optionals cfg.high-memory [ "bitcoin" ];
};
users.groups.${cfg.group} = {};
}