Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

Commit

Permalink
docs: add to FAQ a custom signaling server description (#1104)
Browse files Browse the repository at this point in the history
License: MIT
Signed-off-by: Jorge Ludlow <[email protected]>
  • Loading branch information
AquiGorka authored and daviddias committed Nov 22, 2017
1 parent 71faa92 commit 0258759
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,32 @@ Yes, unfortunately, due to [Chrome aggressive resource throttling policy](https:

A way to mitigate this in Chrome, is to run your IPFS node inside a Service Worker, so that the IPFS instance runs in a background process. You can learn how to install an IPFS node as a service worker in here the repo [ipfs-service-worker](https://github.com/ipfs/ipfs-service-worker)

#### How can I configure an IPFS node to use a custom `signaling server`?

You'll need to execute a compatible `signaling server` ([libp2p-webrtc-star](https://github.com/libp2p/js-libp2p-webrtc-star) works) and to setup the correct configurations params for your IPFS node:

- enable `pubsub`
- provide the [`multiaddr`](https://github.com/multiformats/multiaddr) for the `signaling server`


```JavaScript
const node = new IPFS({
repo: 'your-repo-path',
EXPERIMENTAL: {
pubsub: true,
},
config: {
Addresses: {
Swarm: [
'/ip4/127.0.0.1/tcp/9090/ws/p2p-webrtc-star'
]
}
}
})
```

The code above assumes you are running a local `signaling server` on port `9090`. Provide the correct values accordingly.

## Packages

| Package | Version | Deps | DevDeps | Build |
Expand Down

0 comments on commit 0258759

Please sign in to comment.