# Installation

## Requirements

PHP 8.2+ (8.3 recommended) with PDO, mbstring, OpenSSL, tokenizer, XML, cURL, fileinfo,
ZIP, and the selected database driver; Composer 2; Node 20+; MySQL 8/MariaDB 11;
Redis; a queue supervisor; and a scheduler service.

## Local Windows/XAMPP

```powershell
Copy-Item .env.example .env
C:\xampp\php\php.exe composer.phar install
C:\xampp\php\php.exe artisan key:generate
C:\xampp\php\php.exe artisan migrate --seed
npm install
npm run build
C:\xampp\php\php.exe artisan test
C:\xampp\php\php.exe artisan serve
```

Run a worker and scheduler in separate terminals:

```powershell
C:\xampp\php\php.exe artisan queue:work --tries=3 --timeout=120
C:\xampp\php\php.exe artisan schedule:work
```

## Production preparation

Copy `.env.production.example` to the server's shared `.env`, insert unique secrets,
use a dedicated least-privileged database account, configure Redis/SMTP/S3 and gateway
webhook secrets, and never commit the completed file. Generate `APP_KEY` once; back it
up securely because encrypted data depends on it. Point the web root only at `public/`.

Do not run development seeders in production. Use `php artisan migrate --force`, then
create the first super administrator through a controlled console procedure.
