You've already forked element-web
mirror of
https://github.com/element-hq/element-web.git
synced 2025-11-29 21:23:11 +03:00
cypress: log stdout/stderr when docker exec fails (#9154)
Otherwise you cannot debug anything with errors like: ``` > Command failed: docker exec 134c9a0afd7dadd0b82ce69b4d72d3d6d8ca1b211540d4390a88357b68fa03b9 pg_isready -U postgres ``` Now we include the stdout/err prior to logging this.
This commit is contained in:
@@ -61,9 +61,14 @@ export function dockerExec(args: {
|
|||||||
childProcess.execFile("docker", [
|
childProcess.execFile("docker", [
|
||||||
"exec", args.containerId,
|
"exec", args.containerId,
|
||||||
...args.params,
|
...args.params,
|
||||||
], { encoding: 'utf8' }, err => {
|
], { encoding: 'utf8' }, (err, stdout, stderr) => {
|
||||||
if (err) reject(err);
|
if (err) {
|
||||||
else resolve();
|
console.log(stdout);
|
||||||
|
console.log(stderr);
|
||||||
|
reject(err);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
resolve();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user