Real-time imageboard in node.js and redis
JavaScript CSS HTML C++ C Lua Other
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
admin Show country in mod addrs Sep 14, 2017
archive Pass connection token "ctoken" to SockJS Sep 14, 2017
client Hackily fade inserted images in Mar 11, 2018
curfew Use Date.now() (on node side) Apr 14, 2014
docs nofollow noopener noreferrer Sep 20, 2017
imager Check imager message origin Nov 26, 2017
lib Remove yepnope Feb 10, 2017
lua Use active posts from Lua Feb 2, 2017
report reCAPTCHA 2 Mar 11, 2018
server reCAPTCHA 2 Mar 11, 2018
tmpl nofollow noopener noreferrer Sep 20, 2017
tripcode Tripcode module building tweaks Jun 7, 2017
upkeep Hack-fix upkeep script May 7, 2017
www Hackily fade inserted images in Mar 11, 2018
.gitignore Remove package-lock.json Mar 11, 2018
.ignore Don't grep minified JS Sep 7, 2017
LICENSE 2017 May 17, 2017
Makefile New script-building pipeline Sep 1, 2013
README.md Explicit CloudFlare support; ban by country Sep 7, 2017
TODO
builder.js New script-building pipeline Sep 1, 2013
common.js Allow punctuation near *italics*. Oct 26, 2017
config.js.example Delete voice Sep 14, 2017
db.js Client hot.readOnly setting set by server Sep 7, 2017
deps.js Remove ETags Sep 14, 2017
etc.js json_paranoid Nov 26, 2017
hooks.js Add synchronous hooks May 11, 2013
hot.js.example Hackily fade inserted images in Mar 11, 2018
make_client.js make_client uses Uglify ES Mar 11, 2018
package.json make_client uses Uglify ES Mar 11, 2018
pipeline.js File mode 0644 on pipeline products Sep 1, 2013
tail.js Use setImmediate in tail Aug 17, 2013

README.md

Real-time imageboard. MIT licensed.

Setup:

  • Install dependencies listed below
  • Sign up for reCAPTCHA
  • Create a GitHub Application (callback URL = site URL + /login)
  • Copy config.js.example to config.js and configure
  • Copy hot.js.example to hot.js and configure
  • Copy imager/config.js.example to imager/config.js and configure
  • Copy report/config.js.example to report/config.js and configure
  • You might need to run npm install -g node-gyp
  • Run npm install to install npm deps and compile a few helpers
  • Run node builder.js to run an auto-reloading development server

Production:

  • Have your webserver serve www/ (or wherever you've moved src, thumb, etc.)
    • Configure imager.config.MEDIA_URL appropriately
    • Then turn off SERVE_STATIC_FILES and SERVE_IMAGES
  • If you're behind Cloudflare turn on CLOUDFLARE
    • Or if you're behind any reverse proxy (nginx etc) turn on TRUST_X_FORWARDED_FOR
  • Run node server/server.js for just the server
  • You can update client code & hot.js on-the-fly with node server/kill.js
  • For nginx hosting/reverse proxying, refer to docs/nginx.conf.example
  • For a sample init script, refer to docs/doushio.initscript.example
  • config.DAEMON support is old and broken, PRs welcome

Dependencies:

  • ImageMagick
  • libpng
  • node.js + npm
  • redis
  • ffmpeg 2.2+ if supporting WebM
  • jhead and jpegtran optionally, for EXIF autorotation

Optional npm deps for various features:

  • daemon (broken currently)
  • icecast now-playing banners: node-expat
  • send (if you want to serve static files directly from the node.js process; useful in debug mode also)

Standalone upkeep scripts:

  • archive/daemon.js - moves old threads to the archive
  • upkeep/backup.js - uploads rdb to S3
  • upkeep/clean.js - deletes archived images
  • upkeep/radio.js - icecast2 server integration