Skip to content
A chat server that can run on Raspberry Pi
JavaScript Other
Branch: master
Clone or download
Zohaib
Zohaib Audit fix updating packages
This required updating `gulpfile.js` updating `filters.js` for new
avatars.
Latest commit f1489f4 Jul 29, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src Removing ping generation from server Nov 21, 2017
static Audit fix updating packages Jul 29, 2018
.editorconfig Changing server backend to Node.js Nov 18, 2017
.env
.eslintrc.js Changing server backend to Node.js Nov 18, 2017
.gitattributes Completing REST API and log history limits Jul 3, 2016
.gitignore Changing server backend to Node.js Nov 18, 2017
Readme.md
gulpfile.js Audit fix updating packages Jul 29, 2018
license Completing REST API and log history limits Jul 3, 2016
package-lock.json Audit fix updating packages Jul 29, 2018
package.json Audit fix updating packages Jul 29, 2018
protocol.md Changing server backend to Node.js Nov 18, 2017

Readme.md

An IRC like chat system written in Node.js

Build Status

Demo

Basic demo is available Here.

Why?

I had a spare Raspberry Pi and I wanted to use it! One of ideas in my head was to have your own on-premise chat server that you can use for cheap and own your data (< $50 hardware) forever and free!

Requirements

For compiling you need:

  • Node 8+ (with npm5)
  • libsqlite3
  • OpenSSL 1.x.x (for uWebsockets)
  • zlib 1.x (for uWebsockets)
  • libuv 1.3+ or Boost.Asio 1.x (both optional on Linux)

You can use following commands to install them:

  • Fedora: sudo dnf install openssl-devel zlib-devel
  • Homebrew: brew install openssl zlib libuv
  • Vcpkg: vcpkg install openssl zlib libuv and/or vcpkg install openssl:x64-windows zlib:x64-windows libuv:x64-windows

Once you have installed dependencies above just do npm install && gulp (creates a dist folder that you can upload to your machine). Project can run on almost any machine that nodejs supports. I have successfully tested it on Raspberry Pi, Orange Pi etc.

Configurations

You can use a .env file or environment variables to configure the server, here are the environment variables you can change:

  • RC_URL (default http://localhost:3000/) Raspchat URL where server would start listening
  • DB_PATH (default chat-log.db) Database path for SQLite database
  • WS_URL (default ws://localhost:3000/chat) Websocket URL if you are running it behind some proxy
  • WSS_URL (default wss://localhost:3000/chat) Websocket secure URL if you are running it behind some proxy

You can read about .env file here

Features:

  • Basic GIF support
  • Basic nick support
  • Channel (join/leave/list-members) support
  • Markdown support
  • Message history on group join

Pending:

  • Refactor frontend using hyperapp
  • Scrollable history
  • Unit tests
  • Introduce admin panel with:
    • Reserved alias authorization
    • IP limiting/banning
    • Fixed alias with passwords
You can’t perform that action at this time.