diff --git a/flake.nix b/flake.nix index 46421e7d..d44b231d 100644 --- a/flake.nix +++ b/flake.nix @@ -48,6 +48,8 @@ hyprland.url = "github:hyprwm/Hyprland"; # Steam Deck configs for NixOS jovian.url = "github:Jovian-Experiments/Jovian-NixOS"; + # Bitcoin node + inputs.nix-bitcoin.url = "github:fort-nix/nix-bitcoin/release"; }; outputs = { self, nixpkgs, nixpkgs-wayland, home-manager, lanzaboote, nur, sops-nix, doom-emacs, nixos-generators, deploy-rs, jovian, ... } @inputs: let diff --git a/nixos/hosts/framework-server/bitcoin.nix b/nixos/hosts/framework-server/bitcoin.nix new file mode 100644 index 00000000..6ce1e6dd --- /dev/null +++ b/nixos/hosts/framework-server/bitcoin.nix @@ -0,0 +1,16 @@ +{ inputs, config, pkgs, username, ... }: { + import = [ + inputs.nix-bitcoin.nixosModules.default + # Secure defaults + (inputs.nix-bitcoin + "/modules/presets/secure-node.nix") + ]; + + nix-bitcoin = { + enable = true; + operator = username; + }; + + services.bitcoind.dataDir = "/Storage/bitcoind"; + services.bitcoind.txindex = true; + +} diff --git a/nixos/hosts/framework-server/default.nix b/nixos/hosts/framework-server/default.nix index fa14ba95..5603eb69 100644 --- a/nixos/hosts/framework-server/default.nix +++ b/nixos/hosts/framework-server/default.nix @@ -14,6 +14,7 @@ ./wireguard.nix ./cron.nix ./firewall.nix + ./bitcoin.nix ]; environment.systemPackages = [