paperclipai/paperclip · error
createKubeConfig requires either inCluster=true or a kubecon
Error message
createKubeConfig requires either inCluster=true or a kubeconfig string
What it means
Error "createKubeConfig requires either inCluster=true or a kubeconfig string" thrown in paperclipai/paperclip.
Source
Thrown at packages/plugins/sandbox-providers/kubernetes/src/kube-client.ts:25
RbacAuthorizationV1Api,
} from "@kubernetes/client-node";
export interface CreateKubeConfigInput {
inCluster?: boolean;
kubeconfig?: string;
}
export function createKubeConfig(input: CreateKubeConfigInput): KubeConfig {
const kc = new KubeConfig();
if (input.inCluster) {
kc.loadFromCluster();
return kc;
}
if (input.kubeconfig && input.kubeconfig.trim().length > 0) {
kc.loadFromString(input.kubeconfig);
return kc;
}
throw new Error("createKubeConfig requires either inCluster=true or a kubeconfig string");
}
export interface KubeClients {
core: CoreV1Api;
batch: BatchV1Api;
custom: CustomObjectsApi;
networking: NetworkingV1Api;
rbac: RbacAuthorizationV1Api;
}
export function makeKubeClients(kc: KubeConfig): KubeClients {
return {
core: kc.makeApiClient(CoreV1Api),
batch: kc.makeApiClient(BatchV1Api),
custom: kc.makeApiClient(CustomObjectsApi),
networking: kc.makeApiClient(NetworkingV1Api),
rbac: kc.makeApiClient(RbacAuthorizationV1Api),
};View on GitHub (pinned to 120ae5428f)
Solutions
- Pass inCluster=true when running inside the cluster, or provide a kubeconfig string.
When it happens
Trigger: Thrown at packages/plugins/sandbox-providers/kubernetes/src/kube-client.ts:25 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of paperclipai/paperclip@120ae5428f (2026-08-18).
Data as JSON: /api/errors/b6163c602a69c946.
Report an issue: GitHub.