Skip to content

Commit

Permalink
default to relaysNew for all clusters
Browse files Browse the repository at this point in the history
  • Loading branch information
disassembler committed Mar 26, 2020
1 parent 594cb7f commit 4aa3f72
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion nix/nixos/cardano-node-service.nix
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ in {
type = types.path;
default = commonLib.mkEdgeTopology {
inherit (cfg) port;
inherit (envConfig) edgeNodes;
edgeNodes = [ envConfig.relaysNew ];
};
description = ''
Cluster topology
Expand Down
7 changes: 6 additions & 1 deletion nix/scripts.nix
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,12 @@ let
topologyFile = let
edgePort = if config.useProxy then config.proxyPort else config.edgePort;
edgeHost = if config.useProxy then config.proxyHost else config.edgeHost;
edgeNodes = if config.useProxy then [] else [ config.relaysNew ];
hasCustomEdgeNodes = __hasAttr "edgeNodes" customConfig;
hasRelaysNew = __hasAttr "relaysNew" config;
edgeNodes = let
relaysNodes = [ config.relaysNew ];
edgeNodes' = if (hasCustomEdgeNodes || !hasRelaysNew) then config.edgeNodes else relaysNodes;
in if config.useProxy then [] else edgeNodes';
in config.topologyFile or mkEdgeTopology {
inherit (config) hostAddr port;
inherit edgeNodes edgeHost edgePort;
Expand Down

0 comments on commit 4aa3f72

Please sign in to comment.