Skip to content

Repository files navigation

NodeBB in the Docker

NodeBB Forum Software is powered by Node.js and supports either Redis, MongoDB, or a PostgreSQL database. It utilizes web sockets for instant interactions and real-time notifications. NodeBB has many modern features out of the box such as social network integration and streaming discussions, while still making sure to be compatible with older browsers.

Available tags

Stable releases

latest, v1.15.1, v1.15.0, v1.14.3, v1.14.2 ...

Beta releases

beta, v1.15.1-beta.0, v1.15.0-rc.4, v1.15.0-rc.3, v1.15.0-beta.30 ...

Images delivers through two registries, DockerHub and GitHub Container Registry.

Features

  • Auto installation
  • Auto upgrade when you update image
  • Persistant storage support (official NodeBB image haven't that)

Quick start

Run using Mongo database

docker run --name nodebb -d -p 4567:4567 \
-v ./data:/data \
-e URL="http://mynodebb.com" \
-e DATABASE="mongo" \
-e DB_HOST="host.docker.internal" \
-e DB_USER="mongo_user" \
-e DB_PASSWORD="mongo_pass" \
-e DB_PORT="27017" \
nibrev/nodebb:latest

Run using Redis

docker run --name nodebb -d -p 4567:4567 \
-v ./data:/data \
-e URL="http://localhost" \
-e DATABASE="redis" \
-e DB_NAME="0" \
-e DB_HOST="host.docker.internal" \
-e DB_PASSWORD="redis_pass" \
-e DB_PORT="6379" \
nibrev/nodebb:latest

Run using docker-compose

There is basic docker-compose example to run NodeBB using Redis database.

version: '3.1'services:
nodebb:
image: ghcr.io/rez0n/nodebb:latestrestart: unless-stoppedenvironment:
URL: "http://localhost"DATABASE: "redis"DB_NAME: "0"DB_HOST: "redis"DB_PORT: "6379"volumes:
- ./data/nodebb:/datanetworks:
- nodebbports:
- "4567:4567"redis:
image: redisrestart: unless-stoppedvolumes:
- ./data/redis:/datanetworks:
- nodebbnetworks:
nodebb:
driver: bridge

Run in k8s

This image was adjusted to run in k8s clusters. Example manifest below, you can find full manifests in the k8s-manifests directory.

---
apiVersion: v1kind: PersistentVolumeClaimmetadata:
name: beta-nodebb-pv-claimnamespace: nodebblabels:
app: nodebbspec:
storageClassName: local-pathaccessModes:
- ReadWriteManyresources:
requests:
storage: 1Gi
---
apiVersion: apps/v1kind: Deploymentmetadata:
name: nodebbnamespace: nodebblabels:
app: nodebbspec:
selector:
matchLabels:
app: nodebbtier: frontendstrategy:
type: Recreatetemplate:
metadata:
labels:
app: nodebbtier: frontendspec:
containers:
- image: nibrev/nodebb:betaimagePullPolicy: Alwaysname: nodebbenv:
- name: DATABASEvalue: "redis"
- name: DB_NAMEvalue: "1"
- name: DB_HOSTvalue: redis
- name: DB_PORTvalue: "6379"
- name: URLvalue: "http://node.157.230.78.171.nip.io"ports:
- containerPort: 4567name: nodebbvolumeMounts:
- name: beta-nodebb-pvmountPath: /datavolumes:
- name: beta-nodebb-pvpersistentVolumeClaim:
claimName: beta-nodebb-pv-claim
---
apiVersion: v1kind: Servicemetadata:
name: nodebbnamespace: nodebblabels:
app: nodebbspec:
selector:
app: nodebbtier: frontendports:
- port: 80targetPort: 4567
---
apiVersion: extensions/v1beta1kind: Ingressmetadata:
name: nodebbnamespace: nodebbspec:
rules:
- host: node.157.230.78.171.nip.iohttp:
paths:
- path: /backend:
serviceName: nodebbservicePort: 80

About

NodeBB forum software Docker image with persistent storage support. k8s tested.

Topics

Resources

Stars

31 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages