Class: Cp
Quick start:
const cp = new Cp(kc); cp.cpFromPod(ns, pod, container, srcPath, destPath);— See examples
Defined in: src/cp.ts:7
Constructors
Constructor
new Cp(
config,execInstance?):Cp
Defined in: src/cp.ts:9
Parameters
config
execInstance?
Returns
Cp
Properties
execInstance
execInstance:
Exec
Defined in: src/cp.ts:8
Methods
cpFromPod()
cpFromPod(
namespace,podName,containerName,srcPath,tgtPath,cwd?):Promise<void>
Defined in: src/cp.ts:21
Parameters
namespace
string
The namespace of the pod to exec the command inside.
podName
string
The name of the pod to exec the command inside.
containerName
string
The name of the container in the pod to exec the command inside.
srcPath
string
The source path in the pod
tgtPath
string
The target path in local
cwd?
string
The directory that is used as the parent in the pod when downloading
Returns
Promise<void>
cpToPod()
cpToPod(
namespace,podName,containerName,srcPath,tgtPath):Promise<void>
Defined in: src/cp.ts:60
Parameters
namespace
string
The namespace of the pod to exec the command inside.
podName
string
The name of the pod to exec the command inside.
containerName
string
The name of the container in the pod to exec the command inside.
srcPath
string
The source path in local
tgtPath
string
The target path in the pod
Returns
Promise<void>