Fix: Change DB field 'ports' to 'allocatedPorts' to match schema

Prisma schema defines the field as 'allocatedPorts' (Json type), but code was using 'ports'. This caused DB save failures during provisioning.
This commit is contained in:
jester 2025-12-20 18:07:30 +00:00
parent 61941d50e5
commit 7a336367e9

View File

@ -384,7 +384,7 @@ export async function provisionAgentInstance(body = {}) {
ctype,
hostname,
ip: ctIp,
ports: allocatedPorts,
allocatedPorts: allocatedPorts, // ← FIXED: Was 'ports', now matches schema
payload,
agentState: "running",
agentLastSeen: new Date(),