Keep pause across Coolify restarts, apply the chosen still from the image picker, and remux clips with Range/faststart so finished video can be scrubbed.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Towsty
2026-08-28 08:15:52 -05:00
co-authored by Cursor
parent 870150f052
commit 7d783bd97e
12 changed files with 338 additions and 49 deletions
+11
View File
@@ -52,6 +52,7 @@ export interface PendingJob {
queueId?: string
queueAutoRun?: boolean
queueBudget?: number
stopAfterCurrent?: boolean
}
function pendingRoot() {
@@ -140,6 +141,7 @@ export function pendingFromJob(job: Job, overrides: Partial<PendingJob> = {}): P
queueId: library.queueId,
queueAutoRun: library.queueAutoRun,
queueBudget: library.queueBudget,
stopAfterCurrent: library.stopAfterCurrent,
...overrides
}
}
@@ -185,6 +187,7 @@ export function libraryFromPending(pending: PendingJob): NonNullable<Job['librar
queueId: pending.queueId,
queueAutoRun: pending.queueAutoRun,
queueBudget: pending.queueBudget,
stopAfterCurrent: pending.stopAfterCurrent,
globalLocks: pending.globalLocks,
permanenceRefs: pending.permanenceRefs,
shotPermanenceRefs: pending.shotPermanenceRefs
@@ -198,6 +201,14 @@ export function writePendingJob(job: PendingJob) {
renameSync(tmp, pendingPath(job.jobId))
}
export function patchPendingJob(jobId: string, patch: Partial<PendingJob>) {
const existing = readPendingJob(jobId)
if (!existing) return null
const next = { ...existing, ...patch }
writePendingJob(next)
return next
}
export function readPendingJob(jobId: string): PendingJob | null {
const path = pendingPath(jobId)
if (!existsSync(path)) return null