Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| fc6351b2bc | |||
| cc34e05713 | |||
| 9b951c4308 |
@@ -1,5 +1,7 @@
|
||||
# OpenCode (Kubernetes) Paperclip Adapter Plugin
|
||||
|
||||
> **⚠️ Abandoned** — This adapter is no longer maintained. Please use the new sandbox plugin instead: **[farhoodlabs/paperclip-plugin-k8s](https://github.com/farhoodlabs/paperclip-plugin-k8s)** (`@farhoodlabs/paperclip-plugin-k8s` on npm).
|
||||
|
||||
Paperclip adapter plugin that runs OpenCode agents as isolated Kubernetes Jobs instead of inside the main Paperclip process.
|
||||
|
||||
## Features
|
||||
|
||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "paperclip-adapter-opencode-k8s",
|
||||
"version": "0.2.2",
|
||||
"version": "0.2.3",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "paperclip-adapter-opencode-k8s",
|
||||
"version": "0.2.2",
|
||||
"version": "0.2.3",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@kubernetes/client-node": "^1.0.0",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "paperclip-adapter-opencode-k8s",
|
||||
"version": "0.2.2",
|
||||
"version": "0.2.3",
|
||||
"description": "Paperclip adapter plugin that runs OpenCode agents as Kubernetes Jobs",
|
||||
"license": "MIT",
|
||||
"type": "module",
|
||||
|
||||
@@ -470,12 +470,14 @@ async function streamAndAwaitJob(
|
||||
// Run the file tail and the job-completion poll in parallel so that the
|
||||
// tail loop has a way to stop: when waitForJobCompletion resolves it sets
|
||||
// stopSignal.stopped, which lets tailPodLogFile drain and return.
|
||||
// No completionWithGrace wrapper here — wrapping a long-running job poll
|
||||
// in a 30s grace turns the grace into a hard ceiling and kills runs
|
||||
// prematurely with "Timed out after 0s" when timeoutSec is 0 (no timeout).
|
||||
const completionPromise = waitForJobCompletion(namespace, jobName, completionTimeoutMs, kubeconfigPath)
|
||||
.then((r) => { stopSignal.stopped = true; return r; });
|
||||
const completionGraced = completionWithGrace(completionPromise, LOG_EXIT_COMPLETION_GRACE_MS);
|
||||
const [tailSettled, completionSettled] = await Promise.allSettled([
|
||||
tailPodLogFile(podLogPath, { onLog: wrappedOnLog, stopSignal }),
|
||||
completionGraced,
|
||||
completionPromise,
|
||||
]);
|
||||
stdout = tailSettled.status === "fulfilled" ? tailSettled.value : "";
|
||||
if (completionSettled.status === "rejected") {
|
||||
|
||||
Reference in New Issue
Block a user