chore(dev): add STATUS_PORT env var forwarding to status-go
This commit is contained in:
parent
a9d2ecf839
commit
b0a0b1d4e4
2
Makefile
2
Makefile
|
@ -607,7 +607,7 @@ run: $(RUN_TARGET)
|
|||
|
||||
ICON_TOOL := node_modules/.bin/fileicon
|
||||
|
||||
# Currently not in use: https://github.com/status-im/status-desktop/pull/1858
|
||||
# Will only work at password login. Keycard login doesn't forward the configuration
|
||||
# STATUS_PORT ?= 30306
|
||||
|
||||
run-linux: nim_status_client
|
||||
|
|
|
@ -180,8 +180,6 @@ var NODE_CONFIG* = %* {
|
|||
"EnableNTPSync": true,
|
||||
"KeyStoreDir": "./keystore",
|
||||
"IPFSDir": "./ipfs",
|
||||
# TODO: commented since it's not necessary (we do the connections thru C bindings). Enable it thru an option once status-nodes are able to be configured in desktop
|
||||
#"ListenAddr": ":30304",
|
||||
"LogEnabled": true,
|
||||
"LogFile": "geth.log",
|
||||
"LogLevel": $LogLevel.INFO,
|
||||
|
|
|
@ -284,9 +284,6 @@ proc getDefaultNodeConfig*(self: Service, installationId: string): JsonNode =
|
|||
result["ClusterConfig"]["FilterNodes"] = %* self.fleetConfiguration.getNodes(fleet, FleetNodes.Waku)
|
||||
result["ClusterConfig"]["LightpushNodes"] = %* self.fleetConfiguration.getNodes(fleet, FleetNodes.Waku)
|
||||
|
||||
# TODO: commented since it's not necessary (we do the connections thru C bindings). Enable it thru an option once status-nodes are able to be configured in desktop
|
||||
# result["ListenAddr"] = if existsEnv("STATUS_PORT"): newJString("0.0.0.0:" & $getEnv("STATUS_PORT")) else: newJString("0.0.0.0:30305")
|
||||
|
||||
result["KeyStoreDir"] = newJString(self.keyStoreDir.replace(main_constants.STATUSGODIR, ""))
|
||||
|
||||
proc setLocalAccountSettingsFile(self: Service) =
|
||||
|
@ -508,6 +505,10 @@ proc login*(self: Service, account: AccountDto, password: string): string =
|
|||
"OutputMessageCSVEnabled": output_csv
|
||||
}
|
||||
|
||||
# Source the connection port from the environment for debugging or if default port not accessible
|
||||
if existsEnv("STATUS_PORT"):
|
||||
nodeCfg["ListenAddr"] = newJString("0.0.0.0:" & $getEnv("STATUS_PORT"))
|
||||
|
||||
let response = status_account.login(account.name, account.keyUid, hashedPassword, thumbnailImage,
|
||||
largeImage, $nodeCfg)
|
||||
var error = "response doesn't contain \"error\""
|
||||
|
|
Loading…
Reference in New Issue