Skip to content

Repository files navigation

Lacuna

Lacuna

Community Crowdin

Requirements

  • Node.js 22+
  • pnpm 10+
  • MongoDB 7+
  • Redis 7+
  • Docker & Docker Compose (for containerized development)

Quick start - Local development

Configure environment

See apps/core/.env.example

cp apps/core/.env.example apps/core/.env
# Edit .env with your configuration

Start infrastructure services

# Setup MongoDB and Redis
cd docker
docker compose -f docker-compose.dev.yml up -d

# Setup Lavalink
cd lavalink
cp .env.example .env
# Edit .env with your configuration
docker compose up -d

Install dependencies and run

  1. Install node-gyp
  2. Create a GitHub Personal Access Token with read:packages scope
  3. Save your token as an environment variable
export GITHUB_TOKEN=your_gh_pat
  1. Then run
# Install packages and build
pnpm install --frozen-lockfile
pnpm build
# Start core app
pnpm start
# Start web app dev server
pnpm start:web

Deployment

Prerequisites

  • Docker & Docker Compose
  • MongoDB and Redis already running and reachable. They can be:
    • Running on the host machine
    • Running on a separate server/VPS
    • Running in another Docker network (in which case add them to the lacuna network or expose ports)
  • A domain pointed at the server, with a valid SSL certificate/key pair
  • Sufficient RAM: at least ~3GB free to cover the configured memory limits (can be edited)

Directory layout

Set up the project folder on the server like this:

lacuna/
├── docker-compose.yml
├── .env
└── nginx/
    ├── nginx.conf
    ├── conf.d/
    │   └── upstreams.conf
    └── sites-available/
        └── api.lacunabot.com.conf

See docker for more info.

Environment variables

  1. Create a .env file next to docker-compose.yml and fill it
  2. Verify MongoDB and Redis are reachable from the Docker host before continuing

Nginx and SSL

Make sure the SSL certificate files referenced in docker-compose.yml actually exist on the host at these exact paths:

/etc/ssl/lacunabot.com.pem
/etc/ssl/lacunabot.com.key

The api service only exposes port 5810 internally, so nginx must proxy to it by service name.

Pull the images and start

docker compose pull
docker compose up -d

Start order matters slightly: nginx depends on api, but broker, bot, and api have no explicit dependency on each other in the compose file.

Verify it's running

docker compose ps
docker compose logs -f bot
docker compose logs -f api

# Confirm the API responds behind nginx
curl -I https://your-domain.com

Links

License

Copyright (C) 2020 Daniyar Kurmangaliyev

This project is licensed under the GNU Affero General Public License v3.0 or later - see the LICENSE file for details.

This license applies to this software and its entire commit history, including versions predating the addition of the LICENSE file, effective as of August 22, 2026.

About

Feature-rich Discord bot designed to enhance your community management and moderation experience.

Resources

Stars

3 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages