/** * The confined, ADDITIVE pod-spec patch ({@link PodSpecPatch}/{@link applyPodSpecPatch}) + the exec-socket TLS * shape ({@link execSocketTlsOptions}) + the v4 channel status-frame parse ({@link exitCodeFromStatus}) — the * k8s adapter's protocol/patch layer, independent of pod lifecycle. Split out of `remote-env-k8s.ts` ([ref] * A13, internal-lossless — `remote-env-k8s.ts` re-exports every symbol below unchanged). */ /** * The confined, ADDITIVE pod-spec patch. Every field is purely additive — * none can override the hard isolation invariants. This is the seam the RSI L8 immutable-mount probe + the * graderEnvFactory need. */ export interface PodSpecPatch { /** Appended to spec.volumes (e.g. a read-only configMap/secret/emptyDir for the immutable-oracle mount). */ volumes?: unknown[]; /** Appended to the sandbox container's volumeMounts (e.g. { name, mountPath, readOnly:true } — the RO mount). */ volumeMounts?: unknown[]; /** Merged into the POD-level securityContext (runAsNonRoot, fsGroup, seccompProfile, …). */ podSecurityContext?: Record; /** Merged into the sandbox CONTAINER's securityContext (readOnlyRootFilesystem, capabilities.drop, * allowPrivilegeEscalation:false, …) — the hardening the L8 immutable-mount/isolation probes assert. */ containerSecurityContext?: Record; /** Extra labels merged into metadata.labels (e.g. a grader/probe tag). */ labels?: Record; } /** * Apply a {@link PodSpecPatch} to a sandbox pod object IN PLACE — purely ADDITIVE. Volumes + volumeMounts are * APPENDED (never replaced); securityContext objects are shallow-MERGED onto any existing; labels are merged. It * deliberately touches ONLY spec.volumes / spec.securityContext / containers[0].{volumeMounts,securityContext} / * metadata.labels — so the hard isolation invariants (runtimeClassName, automountServiceAccountToken, * restartPolicy, activeDeadlineSeconds, image, command) are preserved by construction. Pure + exported for testing. */ export declare function applyPodSpecPatch(pod: { metadata: { labels?: Record; }; spec: Record; }, patch: PodSpecPatch): void; /** * TLS options for the exec WebSocket, shaped for BOTH runtimes (2026-06-11 in-cluster drill finding): * Bun's `ws` shim IGNORES node-ws's top-level `ca`/`rejectUnauthorized` (handshake fails against a * cluster CA even with rejectUnauthorized:false) and reads a Bun-specific `tls` sub-object instead; * Node's real `ws` uses the top-level keys and passes the unknown `tls` key harmlessly through to * tls.connect. One merged shape serves both. Live-proven on build-host (probe: top-level ca → TLS handshake * failed; tls.ca → OPEN). */ export declare function execSocketTlsOptions(ca: string | undefined, insecureTls: boolean): Record; /** Parse the v4.channel.k8s.io status frame (channel 3) into an exit code, or a typed failure. */ export declare function exitCodeFromStatus(statusJson: string): { exitCode: number; } | { error: string; }; //# sourceMappingURL=k8s-exec-protocol.d.ts.map