Skip to content

Commit 88c52f8

Browse files
author
Lasim
committed
feat(backend): complete PostgreSQL-only database migration
1 parent 769d557 commit 88c52f8

File tree

152 files changed

+6419
-76431
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

152 files changed

+6419
-76431
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,7 @@ VS Code → HTTPS Request → DeployStack Satellite → MCP Server Process → E
200200
- **[Done]** Integrated OAuth for secure logins (e.g., GitHub)
201201
- **[Done]** Created the initial MCP Server Catalog for tool discovery
202202
- **[Done]** Established documentation and self-hosted Docker support
203+
- **[Done]** PostgreSQL-only database architecture - migrated from multi-database support (SQLite/Turso/PostgreSQL) to PostgreSQL-only for simplified maintenance and enterprise scalability
203204

204205
### **Phase 2: Enterprise Governance** (Completed)
205206

@@ -221,7 +222,7 @@ VS Code → HTTPS Request → DeployStack Satellite → MCP Server Process → E
221222
- **[Done]** **Public Launch** - production satellite for community use
222223
- **[Done]** **Resource Management** - process isolation (remote MCP) and limits
223224
- **[Done]** **GitHub README and Stars Integration** - automatic GitHub data fetching, secure storage, XSS prevention, DoS protection, and audit logging for MCP server catalog enhancement
224-
- **[Done]** **Background Job Queue System** - complete 4-phase custom SQLite-based job queue with worker infrastructure, admin API, frontend monitoring UI, and documentation for long-running tasks
225+
- **[Done]** **Background Job Queue System** - complete 4-phase custom PostgreSQL-based job queue with worker infrastructure, admin API, frontend monitoring UI, and documentation for long-running tasks
225226
- **[Done]** **Cron Job Scheduling System** - recurring task scheduler using node-cron with integration into the job queue system, standard cron expression support, automatic lifecycle management, and complete separation of scheduling logic from execution for reliability and monitoring
226227
- **[Done]** **Frontend Syntax Highlighting** - reusable CodeHighlight component with Prism.js for JSON, JavaScript, TypeScript, Bash, and YAML code blocks
227228
- **[Done]** **Resource Management** - process isolation (stdio) and limits
@@ -264,6 +265,7 @@ VS Code → HTTPS Request → DeployStack Satellite → MCP Server Process → E
264265
- **[Done]** **Satellite Backend Events System** - real-time event processing with convention-based auto-discovery handler pattern, batch processing (1-100 events), partial success handling, JSON schema validation per event type, and extensible architecture supporting MCP client connections, tool executions, server crashes, and custom event types
265266
- **[Done]** **MCP Client Activity Tracking** - personal dashboard feature tracking active MCP clients per user across all components (backend database with mcpClientActivity table, satellite in-memory tracker with 30-second background job reporting via event system, dashboard API endpoint with dual authentication and pagination, client name detection from OAuth/headers/user-agent)
266267
- **[Done]** **Time-Series Metrics System** - production-ready metrics infrastructure with 15-minute bucket aggregation, 3-day retention, automated cleanup
268+
- **[Done]** **PostgreSQL-Only Database Architecture** - complete migration to PostgreSQL with simplified schema management, environment-based configuration, streamlined migration system, and production-ready setup for enterprise scalability
267269

268270
### **Phase 7: Enterprise Features** (Future)
269271

docker-compose.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,27 @@
11
version: '3.8'
22

33
services:
4+
postgres:
5+
image: postgres:18-alpine
6+
container_name: deploystack-postgres
7+
environment:
8+
- POSTGRES_DB=deploystack
9+
- POSTGRES_USER=deploystack
10+
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD:-deploystack}
11+
ports:
12+
- "5432:5432"
13+
volumes:
14+
- deploystack_postgres_data:/var/lib/postgresql/data
15+
networks:
16+
- deploystack-network
17+
restart: unless-stopped
18+
healthcheck:
19+
test: ["CMD-SHELL", "pg_isready -U deploystack -d deploystack"]
20+
interval: 10s
21+
timeout: 5s
22+
retries: 5
23+
start_period: 10s
24+
425
backend:
526
image: deploystack/backend:latest
627
container_name: deploystack-backend
@@ -11,11 +32,20 @@ services:
1132
- PORT=3000
1233
- DEPLOYSTACK_FRONTEND_URL=http://localhost:8080
1334
- DEPLOYSTACK_ENCRYPTION_SECRET=${DEPLOYSTACK_ENCRYPTION_SECRET}
35+
- POSTGRES_HOST=postgres
36+
- POSTGRES_PORT=5432
37+
- POSTGRES_DATABASE=deploystack
38+
- POSTGRES_USER=deploystack
39+
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD:-deploystack}
40+
- POSTGRES_SSL=false
1441
volumes:
1542
- deploystack_backend_persistent:/app/persistent_data
1643
networks:
1744
- deploystack-network
1845
restart: unless-stopped
46+
depends_on:
47+
postgres:
48+
condition: service_healthy
1949
healthcheck:
2050
test: ["CMD", "curl", "-f", "http://localhost:3000/"]
2151
interval: 30s
@@ -39,6 +69,8 @@ services:
3969
condition: service_healthy
4070

4171
volumes:
72+
deploystack_postgres_data:
73+
driver: local
4274
deploystack_backend_persistent:
4375
driver: local
4476

0 commit comments

Comments
 (0)