You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* @param {string} options.listenUri The uri of the host interface to tell express to listen on. Defaults to `http://0.0.0.0:4001
25
27
* @param {boolean} options.i2pEnabled When true, this server will be available over i2p
26
28
* @param {string} options.i2pSamHost The hostname of the i2p SAM control API. Defaults to `127.0.0.1`
27
-
* @param {Integer} options.i2pSamPort The port of the i2p SAM control API. Defaults to `4444`
29
+
* @param {Integer} options.i2pSamPort The port of the i2p SAM control API. Defaults to `7654`
28
30
* @param {string} options.i2pKey When set this i2p key will be used to host the service. If not set a new i2p key will be generated. Defaults to `null`
29
31
* @param {boolean} options.wsEnabled When true the server will host a dataparty websocket service. Defaults to `true`
30
32
* @param {Integer} options.wsPort Port for the websocket service to listen on. Defaults to `null`, using the same port as the http server.
@@ -38,7 +40,7 @@ class ServiceHost {
38
40
listenUri ='http://0.0.0.0:4001',
39
41
i2pEnabled =false,
40
42
i2pSamHost ='127.0.0.1',
41
-
i2pSamPort =4444,
43
+
i2pSamPort =7656,
42
44
i2pKey =null,
43
45
wsEnabled =true,
44
46
wsPort =null,
@@ -107,8 +109,8 @@ class ServiceHost {
107
109
privateKey: reach(i2pKey,'privateKey')
108
110
},
109
111
forward: {
110
-
host: this.apiServerUri.host,
111
-
port: this.apiServerUri.port
112
+
host: '127.0.0.1',//this.apiServerUri.host,
113
+
port: 4001//this.apiServerUri.port
112
114
}
113
115
}
114
116
}
@@ -178,17 +180,30 @@ class ServiceHost {
178
180
}
179
181
180
182
if(this.i2pEnabled&&this.i2p==null){
181
-
debug('starting i2p forward')
183
+
debug('starting i2p forward',this.i2pSettings)
182
184
constSAM=require('@diva.exchange/i2p-sam')
183
185
184
186
this.i2p=awaitSAM.createForward(this.i2pSettings)
185
-
this.i2pUri=this.i2p.getPublicKeys()
187
+
this.i2pUri=this.i2p.getB32Address()
186
188
this.i2pSettings.privateKey=null// clear no longer needed
0 commit comments