Getting Started
Installation
Install PnlTracker on your machine.
Prerequisites
Before starting, make sure you have:
- Docker and Docker Compose installed (recommended)
- OR Node.js 22+ and pnpm (or npm) for a manual installation
Installation with Docker (Recommended)
Clone the repository
Terminal
git clone https://github.com/yopkool29/pnlTracker.git
cd pnlTracker
Configure the environment
Copy the .env.production.example file to .env and edit the values:
Terminal
cp .env.production.example .env
Or use the helper:
Linux / mac
Terminal
./env-create-prod.sh
Windows
Terminal
./env-create-prod.ps1
The helper script automatically generates secure secrets (JWT, PostgreSQL password, admin token). Edit the
.env file only if you need to change ports or other settings.Start the application
In one line (build + start):
Terminal
docker compose up -d --build
Or in two steps:
Terminal
docker compose build
docker compose up -d
Access the application
Open your browser at http://localhost:3001 and log in with:
- Email:
admin@mail.fr - Password:
admin
Manual Installation (without Docker)
Check prerequisites
Terminal
node --version # >= 22
pnpm --version # or npm
Clone and install
Terminal
git clone https://github.com/yopkool29/pnlTracker.git
cd pnlTracker
pnpm install
Configure the environment
Terminal
cp .env.example .env
Edit the
.env fileGenerate Prisma clients
Terminal
# Client for authentication
pnpm prisma generate --schema=prisma/auth/schema.prisma
# Client for data (multi-tenant)
pnpm prisma generate --schema=prisma/data/schema.prisma
Initialize the database and create the admin
Terminal
./scripts/reinit.sh
Warning:
reinit.sh deletes existing data. Only use for the first installation.Start the application
Terminal
# Development mode
pnpm dev
# OR Production mode
pnpm build && pnpm start
Post-installation checklist
- Application accessible at http://localhost:3001
- Login with
admin@mail.fr/admin - Create your first database (isolated PostgreSQL schema for your strategy or period)
- Import your trading data