diff --git a/public/svgs/nodebb.svg b/public/svgs/nodebb.svg new file mode 100644 index 000000000..cc1c56f88 --- /dev/null +++ b/public/svgs/nodebb.svg @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + diff --git a/templates/compose/nodebb.yaml b/templates/compose/nodebb.yaml new file mode 100644 index 000000000..dba35ee6b --- /dev/null +++ b/templates/compose/nodebb.yaml @@ -0,0 +1,60 @@ +# ignore: false +# documentation: https://docs.nodebb.org/ +# slogan: A next-generation discussion platform. +# tags: communication, forums, discussion +# logo: svgs/nodebb.svg +# port: 4567 + +services: + nodebb: + image: ghcr.io/nodebb/nodebb:latest + restart: unless-stopped + environment: + - SERVICE_FQDN_nodebb_4567 + volumes: + - nodebb-build:/usr/src/app/build + - nodebb-uploads:/usr/src/app/public/uploads + - nodebb-config:/opt/config + - type: bind + source: ./.docker/config/setup.json + target: /usr/src/app/setup.json + isDirectory: false + content: | + { + "defaults": { + "postgres": { + "host": "postgres", + "port": 5432, + "database": "nodebb", + "username": "nodebb", + "password": "nodebb" + } + } + } + healthcheck: + test: ["CMD", "curl", "-f", "http://localhost:4567"] + interval: 30s + timeout: 10s + retries: 3 + start_period: 30s + + postgres: + image: postgres:17.2-alpine + restart: unless-stopped + environment: + POSTGRES_USER: nodebb + POSTGRES_PASSWORD: nodebb + POSTGRES_DB: nodebb + volumes: + - postgres-data:/var/lib/postgresql/data + healthcheck: + test: [ "CMD-SHELL", "pg_isready -U nodebb", "-d", "nodebb" ] + interval: 5s + retries: 10 + timeout: 2s + +volumes: + postgres-data: + nodebb-build: + nodebb-uploads: + nodebb-config: \ No newline at end of file