Add liquidd pruning

This commit is contained in:
Jonas Nick 2018-12-06 10:45:45 +00:00
parent 1927fda514
commit 3c7d0c66fb
4 changed files with 6 additions and 1 deletions

View File

@ -25,6 +25,7 @@ in {
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
vim tmux vim tmux
htop
]; ];
nixpkgs.config.packageOverrides = pkgs: { nixpkgs.config.packageOverrides = pkgs: {

View File

@ -64,6 +64,8 @@ in {
chown 'clightning:clightning' '${cfg.dataDir}/config' chown 'clightning:clightning' '${cfg.dataDir}/config'
chmod +w ${cfg.dataDir}/config chmod +w ${cfg.dataDir}/config
chmod o-rw ${cfg.dataDir}/config chmod o-rw ${cfg.dataDir}/config
# The RPC socket has to be removed otherwise we might have stale sockets
rm -f ${cfg.dataDir}/lightning-rpc
echo "bitcoin-rpcpassword=$(cat /secrets/bitcoin-rpcpassword)" >> '${cfg.dataDir}/config' echo "bitcoin-rpcpassword=$(cat /secrets/bitcoin-rpcpassword)" >> '${cfg.dataDir}/config'
''; '';
serviceConfig = serviceConfig =

View File

@ -64,6 +64,7 @@ in {
discover=0 discover=0
''; '';
services.bitcoind.prune = 2000; services.bitcoind.prune = 2000;
services.bitcoind.dbCache = 1000;
services.tor.hiddenServices.bitcoind = { services.tor.hiddenServices.bitcoind = {
map = [{ map = [{
port = config.services.bitcoind.port; port = config.services.bitcoind.port;
@ -119,6 +120,7 @@ in {
services.liquidd.enable = cfg.modules == "all"; services.liquidd.enable = cfg.modules == "all";
services.liquidd.rpcuser = "liquidrpc"; services.liquidd.rpcuser = "liquidrpc";
services.liquidd.prune = 1000;
services.lightning-charge.enable = cfg.modules == "all"; services.lightning-charge.enable = cfg.modules == "all";
services.nanopos.enable = cfg.modules == "all"; services.nanopos.enable = cfg.modules == "all";

View File

@ -35,7 +35,7 @@ in
{ config, pkgs, ... }: { config, pkgs, ... }:
{ {
deployment.targetEnv = "virtualbox"; deployment.targetEnv = "virtualbox";
deployment.virtualbox.memorySize = 2048; # megabytes deployment.virtualbox.memorySize = 4096; # megabytes
deployment.virtualbox.vcpu = 2; # number of cpus deployment.virtualbox.vcpu = 2; # number of cpus
deployment.virtualbox.headless = true; deployment.virtualbox.headless = true;