better named tests and log local-docker params

pull/461/head
Frostebite 2022-09-22 22:42:17 +01:00
parent ffc984be4b
commit 5353abd16e
3 changed files with 19 additions and 12 deletions

4
dist/index.js vendored
View File

@ -3651,11 +3651,11 @@ class LocalDockerCloudRunner {
} }
let myOutput = ''; let myOutput = '';
// core.info(JSON.stringify({ workspace, actionFolder, ...this.buildParameters, ...content }, undefined, 4)); // core.info(JSON.stringify({ workspace, actionFolder, ...this.buildParameters, ...content }, undefined, 4));
const entrypointFilePath = `ls && cd ./.. && ls && ${workspace}/start.sh`; const entrypointFilePath = `${workspace}/start.sh`;
fs_1.writeFileSync(entrypointFilePath, commands, { fs_1.writeFileSync(entrypointFilePath, commands, {
flag: 'w', flag: 'w',
}); });
yield docker_1.default.run(image, Object.assign({ workspace, actionFolder }, this.buildParameters), false, entrypointFilePath, content, { yield docker_1.default.run(image, Object.assign({ workspace, actionFolder }, this.buildParameters), false, `ls && cd ./.. && ls && ${entrypointFilePath}`, content, {
listeners: { listeners: {
stdout: (data) => { stdout: (data) => {
myOutput += data.toString(); myOutput += data.toString();

2
dist/index.js.map vendored

File diff suppressed because one or more lines are too long

View File

@ -84,12 +84,18 @@ class LocalDockerCloudRunner implements ProviderInterface {
let myOutput = ''; let myOutput = '';
// core.info(JSON.stringify({ workspace, actionFolder, ...this.buildParameters, ...content }, undefined, 4)); // core.info(JSON.stringify({ workspace, actionFolder, ...this.buildParameters, ...content }, undefined, 4));
const entrypointFilePath = `ls && cd ./.. && ls && ${workspace}/start.sh`; const entrypointFilePath = `${workspace}/start.sh`;
writeFileSync(entrypointFilePath, commands, { writeFileSync(entrypointFilePath, commands, {
flag: 'w', flag: 'w',
}); });
await Docker.run(image, { workspace, actionFolder, ...this.buildParameters }, false, entrypointFilePath, content, { await Docker.run(
image,
{ workspace, actionFolder, ...this.buildParameters },
false,
`ls && cd ./.. && ls && ${entrypointFilePath}`,
content,
{
listeners: { listeners: {
stdout: (data: Buffer) => { stdout: (data: Buffer) => {
myOutput += data.toString(); myOutput += data.toString();
@ -98,7 +104,8 @@ class LocalDockerCloudRunner implements ProviderInterface {
myOutput += `[LOCAL-DOCKER-ERROR]${data.toString()}`; myOutput += `[LOCAL-DOCKER-ERROR]${data.toString()}`;
}, },
}, },
}); },
);
return myOutput; return myOutput;
} }