feat(FN-317): remove legacy sase-web PM2 entry (+1 more)
Some checks failed
Sync dev → Gitea / Mirror dev to Gitea (push) Has been cancelled
Some checks failed
Sync dev → Gitea / Mirror dev to Gitea (push) Has been cancelled
Commits merged: - docs(FN-317): complete Step 3 — update docs and memory for sase-web removal - feat(FN-317): complete Step 1 — remove legacy sase-web PM2 entry Files changed: .changeset/remove-pm2-sase-web.md | 9 +++++++++ .fusion/memory/MEMORY.md | 2 +- CLAUDE.md | 2 +- docs/INDEX.md | 8 +++----- ecosystem.config.js | 16 ---------------- knowledge.md | 3 +-- 6 files changed, 15 insertions(+), 25 deletions(-) Fusion-Task-Id: FN-317
This commit is contained in:
9
.changeset/remove-pm2-sase-web.md
Normal file
9
.changeset/remove-pm2-sase-web.md
Normal file
@@ -0,0 +1,9 @@
|
||||
---
|
||||
"sase": patch
|
||||
---
|
||||
|
||||
**Removed:** `sase-web` entry from `ecosystem.config.js`
|
||||
|
||||
Production web traffic is served via nginx static files from `apps/web/dist/` (configured in `docker/nginx/sites/sase.tr.conf`). The PM2 `pnpm dev` process on port 3000 was a legacy artifact with `NODE_ENV=development` — it was never in the production serving path. Current production deployment is Coolify-driven (Docker Compose), which builds a single image serving both API (port 4000) and static frontend assets via nginx.
|
||||
|
||||
**Rationale:** Reduce PM2 process footprint, eliminate confusion about which process serves production traffic, and remove a long-running `NODE_ENV=development` process that consumed resources without serving any user traffic.
|
||||
@@ -72,7 +72,7 @@ Highlights to remember:
|
||||
|
||||
## Context
|
||||
|
||||
- **Deploy:** Auto on push to `dev` (→ dev.sase.tr) and `main` (→ sase.tr). Both webhooks live on `git.semih.ai/root/sase.tr` and call Coolify's `/api/v1/deploy?uuid=...&force=true`. No PM2 / GitHub Actions in the loop anymore — the CLAUDE.md mention of `GitHub Actions → SSH → PM2` is historical; current deploy is Coolify-driven.
|
||||
- **Deploy:** Auto on push to `dev` (→ dev.sase.tr) and `main` (→ sase.tr). Both webhooks live on `git.semih.ai/root/sase.tr` and call Coolify's `/api/v1/deploy?uuid=...&force=true`. No PM2 / GitHub Actions in the loop anymore — the CLAUDE.md mention of `GitHub Actions → SSH → PM2` is historical; current deploy is Coolify-driven. The legacy `sase-web` PM2 entry (`pnpm dev`, `NODE_ENV=development`, port 3000) was removed from `ecosystem.config.js` in FN-317 (May 2026). Production web traffic is served via nginx static files from `apps/web/dist/`; PM2 now manages only `sase-api` (port 4000) and `sase-worker`. Web dev on port 3000 remains for local development only (`pnpm dev --filter web`).
|
||||
- **Test admin user:** `admin@sase.tr` / `Sase2026`. Test VIN: `WVWZZZ1JZ3W597935` (VW).
|
||||
- **Critical-path bans on dev:** see team-charter.md. Migrations + dep/config changes still need human ack; auth/payments fixes are auto on dev with QA Lead regression test.
|
||||
- **Critical-path bans on main:** strict — auth/payments/billing/subscription/migrations all gated.
|
||||
|
||||
@@ -57,7 +57,7 @@ ss/
|
||||
├── docker/ # docker-compose.yml (PostgreSQL, Redis, MinIO) + nginx configs
|
||||
├── scripts/ # deploy.sh, test/debug scripts
|
||||
├── docs/ # INDEX.md + detailed docs (00-13)
|
||||
└── ecosystem.config.js # PM2 config (api, web, worker)
|
||||
└── ecosystem.config.js # PM2 config (api, worker)
|
||||
```
|
||||
|
||||
## Key Commands
|
||||
|
||||
@@ -56,10 +56,9 @@ Generated: 2026-03-02
|
||||
└─────────────┘
|
||||
```
|
||||
|
||||
**Three runtime processes** managed by PM2:
|
||||
**Two runtime processes** managed by PM2:
|
||||
1. `sase-api` — NestJS API server (fork mode)
|
||||
2. `sase-web` — Vite/React frontend (fork mode)
|
||||
3. `sase-worker` — Background job processor (fork mode)
|
||||
2. `sase-worker` — Background job processor (fork mode)
|
||||
|
||||
---
|
||||
|
||||
@@ -160,7 +159,7 @@ sase.tr/
|
||||
├── docker/ # Docker Compose (PostgreSQL, Redis, MinIO, nginx)
|
||||
├── scripts/ # Build/deployment/debug scripts
|
||||
├── .github/workflows/ # CI (lint, typecheck, test, build) + Deploy (SSH, PM2)
|
||||
├── ecosystem.config.js # PM2 process configuration
|
||||
├── ecosystem.config.js # PM2 config (api, worker)
|
||||
├── turbo.json # Turborepo task pipeline
|
||||
├── biome.json # Linter/formatter config
|
||||
└── pnpm-workspace.yaml # Workspace root
|
||||
@@ -795,7 +794,6 @@ Dependencies: Radix UI (accordion, dialog, dropdown-menu, label, popover, select
|
||||
| Process | Command | Port | Memory |
|
||||
|---------|---------|------|--------|
|
||||
| `sase-api` | `pnpm dev` (dev) / `dist/main.js` (prod) | 4000 | 512MB |
|
||||
| `sase-web` | `pnpm dev` (dev) / serve dist (prod) | 3000 | 512MB |
|
||||
| `sase-worker` | `dist/worker.js` | — | 256MB |
|
||||
|
||||
---
|
||||
|
||||
@@ -18,22 +18,6 @@ module.exports = {
|
||||
merge_logs: true,
|
||||
log_date_format: "YYYY-MM-DD HH:mm:ss Z",
|
||||
},
|
||||
{
|
||||
name: "sase-web",
|
||||
cwd: "./apps/web",
|
||||
script: "pnpm",
|
||||
args: "dev",
|
||||
exec_mode: "fork",
|
||||
env: {
|
||||
NODE_ENV: "development",
|
||||
PORT: 3000,
|
||||
},
|
||||
max_memory_restart: "512M",
|
||||
error_file: "../../logs/web-error.log",
|
||||
out_file: "../../logs/web-out.log",
|
||||
merge_logs: true,
|
||||
log_date_format: "YYYY-MM-DD HH:mm:ss Z",
|
||||
},
|
||||
{
|
||||
name: "sase-worker",
|
||||
cwd: "./apps/api",
|
||||
|
||||
@@ -133,7 +133,7 @@ ss/ (repo root)
|
||||
├── docker/ # Docker Compose (PostgreSQL, Redis, MinIO, nginx)
|
||||
├── scripts/ # Deploy, debug, keşif script'leri
|
||||
├── .github/workflows/ # CI (lint+typecheck+test+build) + Deploy
|
||||
├── ecosystem.config.js # PM2 process konfigürasyonu
|
||||
├── ecosystem.config.js # PM2 konfigürasyonu (api, worker)
|
||||
├── turbo.json # Turborepo pipeline
|
||||
├── biome.json # Linter/formatter konfigürasyonu
|
||||
└── pnpm-workspace.yaml # Workspace kök
|
||||
@@ -1436,7 +1436,6 @@ Web URL: http://localhost:3000
|
||||
| Süreç | Komut | Port | Max Bellek |
|
||||
|-------|-------|------|------------|
|
||||
| `sase-api` | `dist/main.js` | 4000 | 512MB |
|
||||
| `sase-web` | serve dist | 3000 | 512MB |
|
||||
| `sase-worker` | `dist/worker.js` | — | 256MB |
|
||||
|
||||
### CI/CD (GitHub Actions)
|
||||
|
||||
Reference in New Issue
Block a user