fix(bitcoin): migrate i2pd SAM settings for nixpkgs 26.11
nixpkgs commit c8f9654 refactored the services.i2pd module to use an RFC42-style settings attribute set and removed services.i2pd.proto. After updating the root nixpkgs input from f13ff45 to ec2d622, the vendored bitcoind module failed evaluation on the obsolete services.i2pd.proto.sam.enable definition. The error occurred even with services.bitcoind.i2p at its false default: bitcoind was enabled, so NixOS still validated the obsolete option path inside the conditional i2pd integration. Read the SAM endpoint from services.i2pd.settings.sam and configure its new upstream-style fields explicitly. Keep 127.0.0.1:7656, matching the old typed option defaults that bitcoind uses to generate its i2psam setting. This preserves optional I2P support without activating it by default. i2pd remains disabled until services.bitcoind.i2p is set to true or "only-outgoing". Nixpkgs migration: https://github.com/NixOS/nixpkgs/commit/c8f965411e812060a9377fa4c2d7d0f84e8b10e0
This commit is contained in:
@@ -284,7 +284,9 @@ let
|
||||
nbLib = config.nix-bitcoin.lib;
|
||||
secretsDir = config.nix-bitcoin.secretsDir;
|
||||
|
||||
i2pSAM = config.services.i2pd.proto.sam;
|
||||
# nixpkgs 26.11 moved i2pd's protocol configuration from
|
||||
# `services.i2pd.proto` to the RFC42-style `services.i2pd.settings`.
|
||||
i2pSAM = config.services.i2pd.settings.sam;
|
||||
|
||||
configFile = builtins.toFile "bitcoin.conf" ''
|
||||
# We're already logging via journald
|
||||
@@ -374,7 +376,11 @@ in {
|
||||
|
||||
services.i2pd = mkIf (cfg.i2p != false) {
|
||||
enable = true;
|
||||
proto.sam.enable = true;
|
||||
settings.sam = {
|
||||
enabled = true;
|
||||
address = "127.0.0.1";
|
||||
port = 7656;
|
||||
};
|
||||
};
|
||||
|
||||
systemd.tmpfiles.rules = [
|
||||
|
||||
Reference in New Issue
Block a user