mirror of
https://code.forgejo.org/docker/build-push-action.git
synced 2025-08-17 17:20:53 +00:00
fix: use correct platform when creating remote buildx builder
The remote builder was hardcoded to use --platform linux/amd64 regardless of user input or runner architecture. This caused performance issues on ARM runners and cache inefficiencies. Now properly uses the platforms input or detects host architecture to avoid unnecessary QEMU emulation and improve build performance. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
6fe3b1c366
commit
a7fa33c366
8 changed files with 594 additions and 488 deletions
|
@ -202,7 +202,7 @@ actionsToolkit.run(
|
|||
if (builderInfo.addr) {
|
||||
await core.group(`Creating a builder instance`, async () => {
|
||||
const name = `blacksmith-${Date.now().toString(36)}`;
|
||||
const createCmd = await toolkit.buildx.getCommand(await context.getRemoteBuilderArgs(name, builderInfo.addr!));
|
||||
const createCmd = await toolkit.buildx.getCommand(await context.getRemoteBuilderArgs(name, builderInfo.addr!, inputs.platforms));
|
||||
core.info(`Creating builder with command: ${createCmd.command}`);
|
||||
await Exec.getExecOutput(createCmd.command, createCmd.args, {
|
||||
ignoreReturnCode: true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue