File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -86,6 +86,7 @@ actionsToolkit.run(
86
86
await core . group ( `Builder info` , async ( ) => {
87
87
const builder = await toolkit . builder . inspect ( inputs . builder ) ;
88
88
core . info ( JSON . stringify ( builder , null , 2 ) ) ;
89
+ stateHelper . setBuilder ( builder ) ;
89
90
} ) ;
90
91
91
92
let definition : BakeDefinition | undefined ;
@@ -170,6 +171,10 @@ actionsToolkit.run(
170
171
core . info ( 'Summary disabled' ) ;
171
172
return ;
172
173
}
174
+ if ( stateHelper . builder && stateHelper . builder . driver === 'cloud' ) {
175
+ core . info ( 'Summary is not yet supported with Docker Build Cloud' ) ;
176
+ return ;
177
+ }
173
178
try {
174
179
const buildxHistory = new BuildxHistory ( ) ;
175
180
const exportRes = await buildxHistory . export ( {
Original file line number Diff line number Diff line change 1
1
import * as core from '@actions/core' ;
2
2
3
3
import { BakeDefinition } from '@docker/actions-toolkit/lib/types/buildx/bake' ;
4
+ import { BuilderInfo } from '@docker/actions-toolkit/lib/types/buildx/builder' ;
4
5
5
6
import { Inputs , sanitizeInputs } from './context' ;
6
7
7
8
export const tmpDir = process . env [ 'STATE_tmpDir' ] || '' ;
8
9
export const inputs = process . env [ 'STATE_inputs' ] ? JSON . parse ( process . env [ 'STATE_inputs' ] ) : undefined ;
10
+ export const builder = process . env [ 'STATE_builder' ] ? < BuilderInfo > JSON . parse ( process . env [ 'STATE_builder' ] ) : undefined ;
9
11
export const bakeDefinition = process . env [ 'STATE_bakeDefinition' ] ? < BakeDefinition > JSON . parse ( process . env [ 'STATE_bakeDefinition' ] ) : undefined ;
10
12
export const buildRefs = process . env [ 'STATE_buildRefs' ] ? process . env [ 'STATE_buildRefs' ] . split ( ',' ) : [ ] ;
11
13
@@ -17,6 +19,10 @@ export function setInputs(inputs: Inputs) {
17
19
core . saveState ( 'inputs' , JSON . stringify ( sanitizeInputs ( inputs ) ) ) ;
18
20
}
19
21
22
+ export function setBuilder ( builder : BuilderInfo ) {
23
+ core . saveState ( 'builder' , JSON . stringify ( builder ) ) ;
24
+ }
25
+
20
26
export function setBakeDefinition ( bakeDefinition : BakeDefinition ) {
21
27
core . saveState ( 'bakeDefinition' , JSON . stringify ( bakeDefinition ) ) ;
22
28
}
You can’t perform that action at this time.
0 commit comments