Skip to content

Commit 4d40e96

Browse files
authored
Merge pull request #521 from Nebojsa92/master
Update cp.ts
2 parents ff1d099 + 9472154 commit 4d40e96

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/cp.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export class Cp {
2828
): Promise<void> {
2929
const tmpFile = tmp.fileSync();
3030
const tmpFileName = tmpFile.name;
31-
const command = ['tar', 'cf', '-', srcPath];
31+
const command = ['tar', 'zcf', '-', srcPath];
3232
const writerStream = fs.createWriteStream(tmpFileName);
3333
const errStream = new WritableStreamBuffer();
3434
this.execInstance.exec(

src/cp_test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ describe('Cp', () => {
2121
const container = 'container';
2222
const srcPath = '/';
2323
const tgtPath = '/';
24-
const cmdArray = ['tar', 'cf', '-', srcPath];
24+
const cmdArray = ['tar', 'zcf', '-', srcPath];
2525
const path = `/api/v1/namespaces/${namespace}/pods/${pod}/exec`;
2626

2727
const query = {

0 commit comments

Comments
 (0)