Skip to content

Commit b85ad8e

Browse files
committed
fix: use type=docker output for single-platform builds with platformTag
The devcontainer CLI rejects --platform without --output. For native single-platform builds (platformTag set), use type=docker to load the image into the local daemon for subsequent docker push.
1 parent 569a443 commit b85ad8e

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

github-action/src/main.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,12 @@ export async function runMain(): Promise<void> {
8282
return;
8383
}
8484
}
85-
const buildxOutput = platform && !platformTag ? 'type=oci,dest=/tmp/output.tar' : undefined;
85+
let buildxOutput: string | undefined;
86+
if (platform && !platformTag) {
87+
buildxOutput = 'type=oci,dest=/tmp/output.tar';
88+
} else if (platform && platformTag) {
89+
buildxOutput = 'type=docker';
90+
}
8691

8792
if (platformTag) {
8893
core.saveState('platformTag', platformTag);

0 commit comments

Comments
 (0)