feat: Enable http and websocket rpc client on desktop
This commit is contained in:
parent
588be3c60e
commit
d5084d43e4
|
@ -271,3 +271,14 @@ var NODE_CONFIG* = %* {
|
|||
},
|
||||
"OutputMessageCSVEnabled": false
|
||||
}
|
||||
|
||||
var STATUS_NODE_API_CONFIG* = %* {
|
||||
"APIModules": "connector",
|
||||
"ConnectorEnabled": true,
|
||||
"HTTPEnabled": true,
|
||||
"HTTPHost": "0.0.0.0",
|
||||
"HTTPPort": 8545,
|
||||
"WSEnabled": true,
|
||||
"WSHost": "0.0.0.0",
|
||||
"WSPort": 8586,
|
||||
}
|
||||
|
|
|
@ -40,6 +40,7 @@ type
|
|||
|
||||
keycardInstanceUID*: string
|
||||
keycardPairingDataFile*: string
|
||||
apiConfig*: Option[JsonNode]
|
||||
|
||||
proc toJson*(self: CreateAccountRequest): JsonNode =
|
||||
result = %*{
|
||||
|
@ -91,3 +92,5 @@ proc toJson*(self: CreateAccountRequest): JsonNode =
|
|||
for key, value in self.walletSecretsConfig.toJson().pairs():
|
||||
result[key] = value
|
||||
|
||||
if self.apiConfig.isSome():
|
||||
result["apiConfig"] = %self.apiConfig.get()
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import json
|
||||
import json, std/options
|
||||
import wallet_secretes_config
|
||||
|
||||
export wallet_secretes_config
|
||||
|
@ -14,6 +14,7 @@ type
|
|||
keycardWhisperPrivateKey*: string
|
||||
mnemonic*: string
|
||||
walletSecretsConfig*: WalletSecretsConfig
|
||||
apiConfig*: Option[JsonNode]
|
||||
|
||||
proc toJson*(self: LoginAccountRequest): JsonNode =
|
||||
result = %* {
|
||||
|
@ -28,3 +29,6 @@ proc toJson*(self: LoginAccountRequest): JsonNode =
|
|||
}
|
||||
for key, value in self.walletSecretsConfig.toJson().pairs():
|
||||
result[key] = value
|
||||
|
||||
if self.apiConfig.isSome():
|
||||
result["apiConfig"] = %self.apiConfig.get()
|
||||
|
|
|
@ -238,6 +238,7 @@ QtObject:
|
|||
torrentConfigPort: some(TORRENT_CONFIG_PORT),
|
||||
keycardPairingDataFile: main_constants.KEYCARDPAIRINGDATAFILE,
|
||||
walletSecretsConfig: self.buildWalletSecrets(),
|
||||
apiConfig: some(STATUS_NODE_API_CONFIG)
|
||||
)
|
||||
|
||||
proc createAccountAndLogin*(self: Service, password: string, displayName: string, imagePath: string, imageCropRectangle: ImageCropRectangle): string =
|
||||
|
@ -421,6 +422,7 @@ QtObject:
|
|||
mnemonic: mnemonic,
|
||||
walletSecretsConfig: self.buildWalletSecrets(),
|
||||
bandwidthStatsEnabled: true,
|
||||
apiConfig: some(STATUS_NODE_API_CONFIG)
|
||||
)
|
||||
|
||||
if main_constants.runtimeLogLevelSet():
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 49eaabaca5100368c5b39fb8c107aad2535371e5
|
||||
Subproject commit 1ba4b86c7e2a63864aa84698039e7a1d46082701
|
Loading…
Reference in New Issue