chore: sync port references and docs to 4000s infra
This commit is contained in:
@@ -233,13 +233,13 @@ LOG_LEVEL=info
|
||||
DATABASE_URL=postgresql://user:pass@localhost:5432/discord_moderation
|
||||
# OR
|
||||
DATABASE_HOST=localhost
|
||||
DATABASE_PORT=5432
|
||||
DATABASE_PORT=6432
|
||||
DATABASE_NAME=discord_moderation
|
||||
DATABASE_USER=postgres
|
||||
DATABASE_PASSWORD=secret
|
||||
|
||||
# Redis (optional, for pub/sub)
|
||||
REDIS_URL=redis://localhost:6379
|
||||
REDIS_URL=redis://100.121.180.82:6379
|
||||
|
||||
# Discord
|
||||
MONITOR_GUILD_ID=123456789
|
||||
|
||||
@@ -7,6 +7,6 @@ export default defineConfig({
|
||||
dbCredentials: {
|
||||
url:
|
||||
process.env.DATABASE_URL ||
|
||||
"postgresql://postgres:postgres@localhost:5432/bete",
|
||||
"postgresql://asephs:***@100.121.180.82:6432/dcbot",
|
||||
},
|
||||
});
|
||||
|
||||
@@ -15,7 +15,7 @@ export default defineConfig({
|
||||
// (DISCORD_TOKEN required) and DB-agnostic pure-function tests.
|
||||
env: {
|
||||
DISCORD_TOKEN: "test-discord-token",
|
||||
DATABASE_URL: "postgres://localhost:5432/test",
|
||||
DATABASE_URL: "postgres://localhost:6432/test",
|
||||
AI_ANALYSIS_ENABLED: "true",
|
||||
AI_LLM_API_KEY: "sk-test",
|
||||
},
|
||||
|
||||
@@ -12,7 +12,7 @@ Key points:
|
||||
## Data flow (match these — do not invent endpoints)
|
||||
|
||||
```
|
||||
Discord → discord-gateway → Redis pub/sub → backend (Express :3001) ←→ frontend
|
||||
Discord → discord-gateway → Redis pub/sub → backend (Express :4001) ←→ frontend
|
||||
↑ REST /api/* (same-origin)
|
||||
└ WS /ws (events + PCM binary)
|
||||
```
|
||||
|
||||
@@ -36,6 +36,6 @@ src/
|
||||
|
||||
## API
|
||||
|
||||
Backend berjalan di port 3001. Frontend mengakses API via `window.location` (same-origin atau proxy).
|
||||
Backend berjalan di port 4001. Frontend mengakses API via `window.location` (same-origin atau proxy).
|
||||
|
||||
WebSocket terhubung otomatis ke `/ws` di host yang sama.
|
||||
|
||||
Reference in New Issue
Block a user