1
0
Fork 0
mirror of https://github.com/docker/build-push-action.git synced 2025-06-05 04:01:50 +02:00

set builder driver and endpoint attributes for dbc summary support

Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
This commit is contained in:
CrazyMax 2025-05-27 14:18:13 +02:00
parent 5f9dbf956c
commit 0bb1f27d6b
No known key found for this signature in database
GPG key ID: ADE44D8C9D44FBE4
2 changed files with 18 additions and 4 deletions

View file

@ -85,6 +85,8 @@ actionsToolkit.run(
let builder: BuilderInfo;
await core.group(`Builder info`, async () => {
builder = await toolkit.builder.inspect(inputs.builder);
stateHelper.setBuilderDriver(builder.driver ?? '');
stateHelper.setBuilderEndpoint(builder.nodes?.[0]?.endpoint ?? '');
core.info(JSON.stringify(builder, null, 2));
});
@ -173,8 +175,6 @@ actionsToolkit.run(
core.info('Build summary is not yet supported on GHES');
} else if (!(await toolkit.buildx.versionSatisfies('>=0.13.0'))) {
core.info('Build summary requires Buildx >= 0.13.0');
} else if (builder && builder.driver === 'cloud') {
core.info('Build summary is not yet supported with Docker Build Cloud');
} else if (!ref) {
core.info('Build summary requires a build reference');
} else {
@ -217,7 +217,9 @@ actionsToolkit.run(
await GitHub.writeBuildSummary({
exportRes: exportRes,
uploadRes: uploadRes,
inputs: stateHelper.summaryInputs
inputs: stateHelper.summaryInputs,
driver: stateHelper.builderDriver,
endpoint: stateHelper.builderEndpoint
});
} catch (e) {
core.warning(e.message);