File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
examples/remote-disposable Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change 11/* eslint no-console: 0 */
2-
2+ // @ts -check
33// Start a remote disposable node, and get access to the api
44// print the node id, and stop the temporary daemon
55
6- const { createController, createServer } = require ( '../../src' )
6+ const { path } = require ( 'kubo' )
7+ const { create } = require ( 'kubo-rpc-client' )
8+ /**
9+ * @type {import('../../src') }
10+ */
11+ const { createNode, createServer } = require ( '../../src' )
712const server = createServer ( )
813
914async function run ( ) {
1015 await server . start ( )
11- const node = await createController ( {
16+ const node = await createNode ( {
1217 remote : true ,
13- type : 'go' ,
14- ipfsBin : require ( 'go-ipfs' ) . path ( )
18+ type : 'kubo' ,
19+ bin : path ( ) ,
20+ rpc : create
1521 } )
1622
1723 console . log ( await node . api . id ( ) )
You can’t perform that action at this time.
0 commit comments