Skip to content

Repository files navigation

MyBruteLocal

License TypeScript Node.js React Docker Buy Me a Coffee

A self-hosted fork of LaBrute designed to run entirely on your own machine or LAN. No cloud dependency, no account on an external server. Drop the .bat, click play.

Changes over the upstream:

  • One-click Windows launcher (Lancer_MyBrute.bat) that handles Docker, Postgres, and the dev server automatically.
  • In-app server selector: switch between a local backend and a remote machine (NAS, gaming PC, any host on your LAN) without touching config files.
  • PostgreSQL runs in Docker on port 5433 to avoid conflicts with any existing local Postgres instance.

Stack

Backend: Node.js, Express, Prisma, TypeScript.

Frontend: React, MUI, create-react-app, TypeScript.


Quick start (Windows)

  1. Install Docker Desktop and Node.js (v18+).
  2. Clone the repo and run Lancer_MyBrute.bat.
  3. Pick option 3 to install dependencies, then option 1 to launch.

The launcher starts Docker, waits for Postgres to be ready, then runs yarn dev. The app is available at http://localhost:3000.

On first run, select option 2 to sync the database schema before launching.


Manual setup

1. Clone

git clone https://github.com/infinition/MyBruteLocal.git
cd MyBruteLocal

2. Start the database

docker compose up -d postgres

3. Configure the server

cp server/.env.sample server/.env

Edit server/.env if needed. The defaults work out of the box with the Docker setup.

4. Install dependencies

yarn install

This also runs Prisma migrations and sets up the database schema.

5. Sync the EternalTwin database

yarn eternaltwin db sync

6. Start

yarn dev

Frontend at http://localhost:3000, backend at http://localhost:9000.


Server selection

The settings drawer (gear icon in the app) lets you switch the API endpoint at runtime:

  • Local server: client talks to the backend on the same machine.
  • Remote server: client talks to a backend on another machine.

The remote field accepts any of:

192.168.1.50:9000
http://192.168.1.50:9000
https://my-server.example.com

After saving, the client reloads and uses the new API base URL.


Database

PostgreSQL runs on port 5433 (not the default 5432) to avoid conflicts. The docker-compose.yml creates a named volume labrute_pg_data automatically on first run.

Useful commands:

# Sync schema after a Prisma migration
yarn db:sync:dev

# Seed the database
yarn db:seed

# Reset the database
yarn db:reset

# Open Prisma Studio
yarn studio

Switching between local and remote Postgres is done via DATABASE_URL in server/.env:

# Local
DATABASE_URL="postgresql://postgres:admin@localhost:5433/labrute"

# Remote (NAS, server, etc.)
DATABASE_URL="postgresql://postgres:password@192.168.1.50:5432/labrute"

SQLite

Not supported. The Prisma schema uses PostgreSQL-specific types (UUIDs, arrays, native column types). A SQLite port would require a storage refactor.


Deployment

npm ci                  # Install and build everything
yarn db:sync:prod       # Apply migrations on the production database
yarn start              # Start the backend

Serve the compiled frontend (client/build) with any static server (Nginx, Caddy, etc.).

Environment variables can be overridden at runtime via the Config table in the database without restarting the server.


Development

Editing core

Run yarn core:export after adding or removing files in the core package to update the index exports.

Regenerating the sound spritesheet

Requires ffmpeg and Node v18+.

yarn sfx:generate           # Git Bash
yarn sfx:wsl:generate       # WSL

Updating the sitemap

yarn sitemap:generate

File structure

MyBruteLocal/
  Lancer_MyBrute.bat          # Windows launcher
  docker-compose.yml          # Postgres container
  client/
    public/
      i18n/                   # Translation files
    src/
      components/             # Reusable components
      hooks/                  # React hooks
      layouts/
      theme/
      utils/
      views/
  core/                       # Shared code (front + back)
    src/
  server/
    prisma/                   # DB schema and migrations
    src/
      controllers/
      utils/
  prisma/                     # Shared Prisma types

Star History

Star History Chart

Credits

Based on LaBrute by Zenoo.

License

CC BY-NC-SA 4.0. See LICENSE.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages