Skip to content

Commit

Permalink
Merge pull request #111 from crazy-max/fix-buildx-build-err
Browse files Browse the repository at this point in the history
buildx(install): throw error on failed build
  • Loading branch information
crazy-max committed Jun 7, 2023
2 parents 0b166c6 + e072607 commit a5b683b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/buildx/install.ts
Expand Up @@ -86,7 +86,7 @@ export class Install {
ignoreReturnCode: true
}).then(res => {
if (res.stderr.length > 0 && res.exitCode != 0) {
core.warning(res.stderr.trim());
throw new Error(`build failed with: ${res.stderr.match(/(.*)\s*$/)?.[0]?.trim() ?? 'unknown error'}`);
}
return tc.cacheFile(`${outputDir}/buildx`, os.platform() == 'win32' ? 'docker-buildx.exe' : 'docker-buildx', 'buildx', vspec, this.platform());
});
Expand Down

0 comments on commit a5b683b

Please sign in to comment.