stockholm/lass/2configs/bitcoin.nix

34 lines
707 B
Nix
Raw Normal View History

2015-07-16 13:51:01 +00:00
{ config, pkgs, ... }:
2016-01-19 18:59:53 +00:00
let
mainUser = config.users.extraUsers.mainUser;
in {
2015-07-16 13:51:01 +00:00
2017-08-06 14:10:01 +00:00
krebs.per-user.bch.packages = [
pkgs.electron-cash
];
krebs.per-user.bitcoin.packages = [
pkgs.electrum
];
2015-07-16 13:51:01 +00:00
users.extraUsers = {
2017-08-06 14:10:01 +00:00
bch = {
name = "bch";
description = "user for bch stuff";
home = "/home/bch";
useDefaultShell = true;
createHome = true;
};
2015-07-16 13:51:01 +00:00
bitcoin = {
name = "bitcoin";
description = "user for bitcoin stuff";
home = "/home/bitcoin";
useDefaultShell = true;
createHome = true;
};
};
2016-01-19 18:59:53 +00:00
security.sudo.extraConfig = ''
${mainUser.name} ALL=(bitcoin) NOPASSWD: ALL
2017-08-06 14:10:01 +00:00
${mainUser.name} ALL=(bch) NOPASSWD: ALL
2016-01-19 18:59:53 +00:00
'';
2015-07-16 13:51:01 +00:00
}