mirror of
https://github.com/docker/build-push-action.git
synced 2026-01-21 10:08:54 +08:00
feat: add support for Docker Build Cloud summary and refactor summary state
- Add summaryType state to distinguish between buildx and cloud summaries. - Generate a Docker Build Cloud summary with a direct link to build details on app.docker.com when using the cloud driver. - Refactor state-helper to use summaryType instead of isSummarySupported. - Improve summary selection logic and output for both buildx and cloud drivers. - Add informative logging for cloud build summary links. Signed-off-by: Nicolas Beck <nicolas.beck@docker.com>
This commit is contained in:
parent
14487ce63c
commit
926b923d82
2 changed files with 20 additions and 7 deletions
|
|
@ -6,7 +6,7 @@ import {Inputs} from './context';
|
|||
|
||||
export const tmpDir = process.env['STATE_tmpDir'] || '';
|
||||
export const buildRef = process.env['STATE_buildRef'] || '';
|
||||
export const isSummarySupported = !!process.env['STATE_isSummarySupported'];
|
||||
export const summaryType = process.env['STATE_summaryType'] || undefined;
|
||||
export const summaryInputs = process.env['STATE_summaryInputs'] ? JSON.parse(process.env['STATE_summaryInputs']) : undefined;
|
||||
|
||||
export function setTmpDir(tmpDir: string) {
|
||||
|
|
@ -17,8 +17,8 @@ export function setBuildRef(buildRef: string) {
|
|||
core.saveState('buildRef', buildRef);
|
||||
}
|
||||
|
||||
export function setSummarySupported() {
|
||||
core.saveState('isSummarySupported', 'true');
|
||||
export function setSummaryType(summaryType: string) {
|
||||
core.saveState('summaryType', summaryType);
|
||||
}
|
||||
|
||||
export function setSummaryInputs(inputs: Inputs) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue