From aa0044f64a9360e14d3350c580acc577a068b9e1 Mon Sep 17 00:00:00 2001 From: ehsan shariati Date: Sat, 24 Feb 2024 22:01:42 +0100 Subject: [PATCH] Update main.go --- modules/initipfs/main.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/modules/initipfs/main.go b/modules/initipfs/main.go index 4ebc0fa..30350be 100644 --- a/modules/initipfs/main.go +++ b/modules/initipfs/main.go @@ -336,6 +336,10 @@ func updateDatastorePath(ipfsCfg *IPFSConfig, newPath string) { // Update the path to the new specified path ipfsCfg.Addresses.Gateway = "/ip4/127.0.0.1/tcp/8081" } + if ipfsCfg.Addresses.Gateway != "" { + // Update the path to the new specified path + ipfsCfg.Addresses.API = "/ip4/0.0.0.0/tcp/5001" + } } func generatePeerIDFromIdentity(identity string) string {