From 2d5ab372e74d7e307e2f845da2ea0b73e55d2ea6 Mon Sep 17 00:00:00 2001 From: JohnySigma Date: Thu, 4 Dec 2025 10:32:37 +0200 Subject: [PATCH] fix/dev-config-raft-adv set RQLiteRaftInternalPort and advertised addresses to fix health checks --- pkg/environments/development/config.go | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) diff --git a/pkg/environments/development/config.go b/pkg/environments/development/config.go index 66b4904..9d95bd6 100644 --- a/pkg/environments/development/config.go +++ b/pkg/environments/development/config.go @@ -143,16 +143,21 @@ func (ce *ConfigEnsurer) ensureNodeConfig(nodeSpec NodeSpec, peerAddrs []string) // Generate node config (all nodes are unified) data := templates.NodeConfigData{ - NodeID: nodeSpec.Name, - P2PPort: nodeSpec.P2PPort, - DataDir: nodeDir, - RQLiteHTTPPort: nodeSpec.RQLiteHTTPPort, - RQLiteRaftPort: nodeSpec.RQLiteRaftPort, - RQLiteJoinAddress: nodeSpec.RQLiteJoinTarget, - BootstrapPeers: peerAddrs, - ClusterAPIPort: nodeSpec.ClusterAPIPort, - IPFSAPIPort: nodeSpec.IPFSAPIPort, - UnifiedGatewayPort: nodeSpec.UnifiedGatewayPort, + NodeID: nodeSpec.Name, + P2PPort: nodeSpec.P2PPort, + DataDir: nodeDir, + RQLiteHTTPPort: nodeSpec.RQLiteHTTPPort, + RQLiteRaftPort: nodeSpec.RQLiteRaftPort, + // Internal Raft port is the same as the external in local dev + RQLiteRaftInternalPort: nodeSpec.RQLiteRaftPort, + RQLiteJoinAddress: nodeSpec.RQLiteJoinTarget, + BootstrapPeers: peerAddrs, + ClusterAPIPort: nodeSpec.ClusterAPIPort, + IPFSAPIPort: nodeSpec.IPFSAPIPort, + UnifiedGatewayPort: nodeSpec.UnifiedGatewayPort, + // Advertise local addresses for HTTP and Raft in dev + HTTPAdvAddress: fmt.Sprintf("localhost:%d", nodeSpec.UnifiedGatewayPort), + RaftAdvAddress: fmt.Sprintf("localhost:%d", nodeSpec.RQLiteRaftPort), } config, err := templates.RenderNodeConfig(data)