sman591 / discourse-nntp-bridge

Discourse plugin to keep NNTP & Discourse in sync
MIT License
19 stars 2 forks source link
discourse nntp

discourse-nntp-bridge Build Status Code Climate security

NNTP bridge to keep NNTP & Discourse in sync

Primarily used for keeping CSH Discourse in sync with the CSH news server.

Installation

  1. Add https://github.com/sman591/discourse-nntp-bridge.git as a plugin
  2. Add NEWS_HOST, NEWS_USERNAME, and NEWS_PASSWORD environment variables to your app.yml
  3. Rebuild your app: ./launcher rebuild app
  4. Enter the app: ./launcher enter app
  5. Run rake discourse_nntp_bridge:assign_newsgroups to assign newsgroups to your already-created categories

NNTP Communication

The only required environment variable is NEWS_HOST. NEWS_USERNAME and NEWS_PASSWORD are both optional, and at least one of the two must be present in order to send authentication along with NNTP.

Most of the NNTP communication was written by Alex Grant for CSH WebNews, and is used/adapted upon heavily throughout this plugin.

Development

Development requires running a local copy of the latest-release of Discourse.

Assuming you store repositories in ~/dev, the Discourse repo should be located at ~/dev/discourse and the NNTP bridge repo should be at ~/dev/discourse-nntp-bridge.

cd ~/dev/
git clone git@github.com:discourse/discourse.git
cd discourse
git fetch --tags
git checkout tags/latest-release
cd plugins && ln -s ../../discourse-nntp-bridge && cd ../

This clones Discourse, checks out the latest-release tag, and adds discourse-nntp-bridge to the plugin directory via a symlink --- making it easy to make changes to the plugin in development.

After this, you'll want to get Discourse set up & running locally. See Discourse's README for more info!