Skip to content

bitxenia/astrawiki

Repository files navigation

Astrawiki

The Bitxenia Astrawiki node is an implementation of a client for a decentralized peer-to-peer read-write wiki within the IPFS ecosystem. It leverages technologies such as OrbitDB for the database and LibP2P for peer-to-peer communication between collaborators. With this node, users can connect to an existing wiki or create their own, allowing to create, read, and edit articles in a collaborative manner.

The implementation focuses on providing a decentralized, distributed, and collaborative alternative to existing wikis. For this reason, only the collaborative nodes are responsible for the availability and persistence of the wiki.

To achieve true decentralization, all nodes that make up the wiki share the same responsibilities, making it easy to create or maintain a wiki separate from the one provided by Bitxenia. Additionally, no wiki depends on its original creators.

By using OrbitDB as a database, any user can create and edit articles in real-time.

A frontend client can be built using the node to make the wiki more accessible. The node can be used locally or from a web application. At Bitxenia, we provide our own web client, but users are free to create their own if desired.

Install

npm install @bitxenia/astrawiki

Usage

Using the createAstrawiki init function you can create and connect the node to a wiki.

import { createAstrawiki } from "@bitxenia/astrawiki";

const node = await createAstrawiki({
  wikiName: "bitxenia-wiki",
});

const articleList = await node.getArticleList();
console.log(articleList);

Use the Getting Started guide for an initial introduction to the Astrawiki node usage.

Documentation

You can find more advanced topics in our docs.

Development

Clone and install dependencies:

git clone [email protected]:bitxenia/astrawiki.git
cd astrawiki
npm install

Run Tests

npm run test

Build

npm run build

Contribute

Contributions welcome! Please check out the issues.

Troubleshooting

The node cannot receive incoming connections and, as a result, cannot collaborate.

If the node is set to collaborate and it fails to do so, the reason should most likely be a port issue. The LibP2P implementation uses UPnP to automatically open ports and detect the public IP. If the modem is outdated, you will need to manually open the ports and specify the public IP when creating the node in the createAstrawikiNode init function.

The ports that need to be opened manually are:

  • 40001 TCP port, used to receive TCP incoming connections.
  • 40001 UDP port, used to receive WebRTC-Direct incoming connections.

If this does not work, your ISP may be using Double NAT, which prevents incoming connections. In this case, you may need to contact your ISP to request a solution.

Other implementations

License

MIT (LICENSE-MIT / http://opensource.org/licenses/MIT)

Packages

No packages published

Contributors 2

  •  
  •