| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  | import {afterEach, beforeEach, describe, expect, jest, test} from '@jest/globals'; | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  | import * as fs from 'fs'; | 
					
						
							|  |  |  | import * as path from 'path'; | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | import {Builder} from '@docker/actions-toolkit/lib/buildx/builder'; | 
					
						
							|  |  |  | import {Buildx} from '@docker/actions-toolkit/lib/buildx/buildx'; | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  | import {Build} from '@docker/actions-toolkit/lib/buildx/build'; | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | import {Context} from '@docker/actions-toolkit/lib/context'; | 
					
						
							| 
									
										
										
										
											2023-03-12 23:34:24 +01:00
										 |  |  | import {Docker} from '@docker/actions-toolkit/lib/docker/docker'; | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | import {GitHub} from '@docker/actions-toolkit/lib/github'; | 
					
						
							|  |  |  | import {Toolkit} from '@docker/actions-toolkit/lib/toolkit'; | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-05-27 12:45:25 +02:00
										 |  |  | import {BuilderInfo} from '@docker/actions-toolkit/lib/types/buildx/builder'; | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | import {GitHubRepo} from '@docker/actions-toolkit/lib/types/github'; | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-10-21 21:07:52 +02:00
										 |  |  | import * as context from '../src/context'; | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | const tmpDir = path.join('/tmp', '.docker-build-push-jest'); | 
					
						
							|  |  |  | const tmpName = path.join(tmpDir, '.tmpname-jest'); | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | import repoFixture from './fixtures/github-repo.json'; | 
					
						
							|  |  |  | jest.spyOn(GitHub.prototype, 'repoData').mockImplementation((): Promise<GitHubRepo> => { | 
					
						
							|  |  |  |   return <Promise<GitHubRepo>>(repoFixture as unknown); | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  | }); | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | jest.spyOn(Context, 'tmpDir').mockImplementation((): string => { | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |   if (!fs.existsSync(tmpDir)) { | 
					
						
							|  |  |  |     fs.mkdirSync(tmpDir, {recursive: true}); | 
					
						
							|  |  |  |   } | 
					
						
							|  |  |  |   return tmpDir; | 
					
						
							|  |  |  | }); | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | jest.spyOn(Context, 'tmpName').mockImplementation((): string => { | 
					
						
							|  |  |  |   return tmpName; | 
					
						
							|  |  |  | }); | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | jest.spyOn(Docker, 'isAvailable').mockImplementation(async (): Promise<boolean> => { | 
					
						
							|  |  |  |   return true; | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  | }); | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  | const metadataJson = path.join(tmpDir, 'metadata.json'); | 
					
						
							|  |  |  | jest.spyOn(Build.prototype, 'getMetadataFilePath').mockImplementation((): string => { | 
					
						
							|  |  |  |   return metadataJson; | 
					
						
							|  |  |  | }); | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | const imageIDFilePath = path.join(tmpDir, 'iidfile.txt'); | 
					
						
							|  |  |  | jest.spyOn(Build.prototype, 'getImageIDFilePath').mockImplementation((): string => { | 
					
						
							|  |  |  |   return imageIDFilePath; | 
					
						
							|  |  |  | }); | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  | jest.spyOn(Builder.prototype, 'inspect').mockImplementation(async (): Promise<BuilderInfo> => { | 
					
						
							|  |  |  |   return { | 
					
						
							|  |  |  |     name: 'builder2', | 
					
						
							|  |  |  |     driver: 'docker-container', | 
					
						
							|  |  |  |     lastActivity: new Date('2023-01-16 09:45:23 +0000 UTC'), | 
					
						
							|  |  |  |     nodes: [ | 
					
						
							|  |  |  |       { | 
					
						
							| 
									
										
										
										
											2023-03-12 23:34:24 +01:00
										 |  |  |         buildkit: 'v0.11.0', | 
					
						
							|  |  |  |         'buildkitd-flags': '--debug --allow-insecure-entitlement security.insecure --allow-insecure-entitlement network.host', | 
					
						
							|  |  |  |         'driver-opts': ['BUILDKIT_STEP_LOG_MAX_SIZE=10485760', 'BUILDKIT_STEP_LOG_MAX_SPEED=10485760', 'JAEGER_TRACE=localhost:6831', 'image=moby/buildkit:latest', 'network=host'], | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         endpoint: 'unix:///var/run/docker.sock', | 
					
						
							|  |  |  |         name: 'builder20', | 
					
						
							|  |  |  |         platforms: 'linux/amd64,linux/amd64/v2,linux/amd64/v3,linux/arm64,linux/riscv64,linux/ppc64le,linux/s390x,linux/386,linux/mips64le,linux/mips64,linux/arm/v7,linux/arm/v6', | 
					
						
							|  |  |  |         status: 'running' | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  |     ] | 
					
						
							|  |  |  |   }; | 
					
						
							|  |  |  | }); | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  | describe('getArgs', () => { | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |   const originalEnv = process.env; | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |   beforeEach(() => { | 
					
						
							|  |  |  |     process.env = Object.keys(process.env).reduce((object, key) => { | 
					
						
							|  |  |  |       if (!key.startsWith('INPUT_')) { | 
					
						
							|  |  |  |         object[key] = process.env[key]; | 
					
						
							|  |  |  |       } | 
					
						
							|  |  |  |       return object; | 
					
						
							|  |  |  |     }, {}); | 
					
						
							|  |  |  |   }); | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |   afterEach(() => { | 
					
						
							|  |  |  |     process.env = originalEnv; | 
					
						
							|  |  |  |   }); | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  |   // prettier-ignore
 | 
					
						
							|  |  |  |   test.each([ | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       0, | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |       '0.4.1', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       1, | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |         ['build-args', `MY_ARG=val1,val2,val3
 | 
					
						
							|  |  |  | ARG=val | 
					
						
							|  |  |  | "MULTILINE=aaaa | 
					
						
							|  |  |  | bbbb | 
					
						
							|  |  |  | ccc"`],
 | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2020-10-20 19:04:54 +02:00
										 |  |  |         '--build-arg', 'MY_ARG=val1,val2,val3', | 
					
						
							|  |  |  |         '--build-arg', 'ARG=val', | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |         '--build-arg', `MULTILINE=aaaa\nbbbb\nccc`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2020-12-05 03:40:39 +01:00
										 |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       2, | 
					
						
							| 
									
										
										
										
											2020-12-05 03:40:39 +01:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['tags', 'name/app:7.4, name/app:latest'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-12-05 03:40:39 +01:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2020-12-05 03:40:39 +01:00
										 |  |  |         '--tag', 'name/app:7.4', | 
					
						
							|  |  |  |         '--tag', 'name/app:latest', | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-12-05 03:40:39 +01:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       3, | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							| 
									
										
										
										
											2020-10-20 19:04:54 +02:00
										 |  |  |         ['labels', 'org.opencontainers.image.title=buildkit\norg.opencontainers.image.description=concurrent, cache-efficient, and Dockerfile-agnostic builder toolkit'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['outputs', 'type=local,dest=./release-out'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2020-10-20 19:04:54 +02:00
										 |  |  |         '--label', 'org.opencontainers.image.title=buildkit', | 
					
						
							|  |  |  |         '--label', 'org.opencontainers.image.description=concurrent, cache-efficient, and Dockerfile-agnostic builder toolkit', | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |         '--output', 'type=local,dest=./release-out', | 
					
						
							|  |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       4, | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |       '0.4.1', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['platforms', 'linux/amd64,linux/arm64'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							|  |  |  |         '--platform', 'linux/amd64,linux/arm64', | 
					
						
							|  |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-10-21 09:51:06 +02:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       5, | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       '0.4.1', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       6, | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							| 
									
										
										
										
											2020-10-23 12:21:44 -04:00
										 |  |  |         ['secrets', 'GIT_AUTH_TOKEN=abcdefghijklmno=0123456789'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         '--secret', `id=GIT_AUTH_TOKEN,src=${tmpName}`, | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       7, | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							| 
									
										
										
										
											2020-10-20 15:18:02 +02:00
										 |  |  |         ['github-token', 'abcdefghijklmno0123456789'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['outputs', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2020-10-20 15:18:02 +02:00
										 |  |  |         '--output', '.', | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         '--secret', `id=GIT_AUTH_TOKEN,src=${tmpName}`, | 
					
						
							|  |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-10-21 02:46:41 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       8, | 
					
						
							| 
									
										
										
										
											2020-10-21 02:46:41 +02:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							| 
									
										
										
										
											2021-04-26 11:02:09 +02:00
										 |  |  |         ['context', 'https://github.com/docker/build-push-action.git#refs/heads/master'], | 
					
						
							| 
									
										
										
										
											2020-10-21 02:46:41 +02:00
										 |  |  |         ['tag', 'localhost:5000/name/app:latest'], | 
					
						
							|  |  |  |         ['platforms', 'linux/amd64,linux/arm64'], | 
					
						
							| 
									
										
										
										
											2020-10-23 12:21:44 -04:00
										 |  |  |         ['secrets', 'GIT_AUTH_TOKEN=abcdefghijklmno=0123456789'], | 
					
						
							| 
									
										
										
										
											2020-10-21 02:46:41 +02:00
										 |  |  |         ['file', './test/Dockerfile'], | 
					
						
							|  |  |  |         ['builder', 'builder-git-context-2'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'true'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-10-21 02:46:41 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |         '--file', './test/Dockerfile', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |         '--platform', 'linux/amd64,linux/arm64', | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         '--secret', `id=GIT_AUTH_TOKEN,src=${tmpName}`, | 
					
						
							| 
									
										
										
										
											2020-10-21 02:46:41 +02:00
										 |  |  |         '--builder', 'builder-git-context-2', | 
					
						
							|  |  |  |         '--push', | 
					
						
							| 
									
										
										
										
											2021-04-26 11:02:09 +02:00
										 |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       9, | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							| 
									
										
										
										
											2021-04-26 11:02:09 +02:00
										 |  |  |         ['context', 'https://github.com/docker/build-push-action.git#refs/heads/master'], | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |         ['tag', 'localhost:5000/name/app:latest'], | 
					
						
							|  |  |  |         ['platforms', 'linux/amd64,linux/arm64'], | 
					
						
							|  |  |  |         ['secrets', `GIT_AUTH_TOKEN=abcdefghi,jklmno=0123456789
 | 
					
						
							|  |  |  | "MYSECRET=aaaaaaaa | 
					
						
							|  |  |  | bbbbbbb | 
					
						
							|  |  |  | ccccccccc" | 
					
						
							|  |  |  | FOO=bar | 
					
						
							|  |  |  | "EMPTYLINE=aaaa | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | bbbb | 
					
						
							|  |  |  | ccc"`],
 | 
					
						
							|  |  |  |         ['file', './test/Dockerfile'], | 
					
						
							|  |  |  |         ['builder', 'builder-git-context-2'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'true'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |         '--file', './test/Dockerfile', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |         '--platform', 'linux/amd64,linux/arm64', | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         '--secret', `id=GIT_AUTH_TOKEN,src=${tmpName}`, | 
					
						
							|  |  |  |         '--secret', `id=MYSECRET,src=${tmpName}`, | 
					
						
							|  |  |  |         '--secret', `id=FOO,src=${tmpName}`, | 
					
						
							|  |  |  |         '--secret', `id=EMPTYLINE,src=${tmpName}`, | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |         '--builder', 'builder-git-context-2', | 
					
						
							|  |  |  |         '--push', | 
					
						
							| 
									
										
										
										
											2021-04-26 11:02:09 +02:00
										 |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       10, | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							| 
									
										
										
										
											2021-04-26 11:02:09 +02:00
										 |  |  |         ['context', 'https://github.com/docker/build-push-action.git#refs/heads/master'], | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |         ['tag', 'localhost:5000/name/app:latest'], | 
					
						
							|  |  |  |         ['platforms', 'linux/amd64,linux/arm64'], | 
					
						
							|  |  |  |         ['secrets', `GIT_AUTH_TOKEN=abcdefghi,jklmno=0123456789
 | 
					
						
							|  |  |  | MYSECRET=aaaaaaaa | 
					
						
							|  |  |  | bbbbbbb | 
					
						
							|  |  |  | ccccccccc | 
					
						
							|  |  |  | FOO=bar | 
					
						
							|  |  |  | EMPTYLINE=aaaa | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | bbbb | 
					
						
							|  |  |  | ccc`],
 | 
					
						
							|  |  |  |         ['file', './test/Dockerfile'], | 
					
						
							|  |  |  |         ['builder', 'builder-git-context-2'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'true'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |         '--file', './test/Dockerfile', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |         '--platform', 'linux/amd64,linux/arm64', | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         '--secret', `id=GIT_AUTH_TOKEN,src=${tmpName}`, | 
					
						
							|  |  |  |         '--secret', `id=MYSECRET,src=${tmpName}`, | 
					
						
							|  |  |  |         '--secret', `id=FOO,src=${tmpName}`, | 
					
						
							|  |  |  |         '--secret', `id=EMPTYLINE,src=${tmpName}`, | 
					
						
							| 
									
										
										
										
											2020-11-17 21:38:45 +01:00
										 |  |  |         '--builder', 'builder-git-context-2', | 
					
						
							|  |  |  |         '--push', | 
					
						
							| 
									
										
										
										
											2021-04-26 11:02:09 +02:00
										 |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2021-02-15 10:08:19 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       11, | 
					
						
							| 
									
										
										
										
											2021-02-15 10:08:19 +01:00
										 |  |  |       '0.5.1', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							| 
									
										
										
										
											2021-04-26 11:02:09 +02:00
										 |  |  |         ['context', 'https://github.com/docker/build-push-action.git#refs/heads/master'], | 
					
						
							| 
									
										
										
										
											2021-02-15 10:08:19 +01:00
										 |  |  |         ['tag', 'localhost:5000/name/app:latest'], | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         ['secret-files', `MY_SECRET=${path.join(__dirname, 'fixtures', 'secret.txt')}`], | 
					
						
							| 
									
										
										
										
											2021-02-15 10:08:19 +01:00
										 |  |  |         ['file', './test/Dockerfile'], | 
					
						
							|  |  |  |         ['builder', 'builder-git-context-2'], | 
					
						
							| 
									
										
										
										
											2021-04-06 14:49:15 +02:00
										 |  |  |         ['network', 'host'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'true'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2021-02-15 10:08:19 +01:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |         '--file', './test/Dockerfile', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         '--secret', `id=MY_SECRET,src=${tmpName}`, | 
					
						
							| 
									
										
										
										
											2021-02-15 10:08:19 +01:00
										 |  |  |         '--builder', 'builder-git-context-2', | 
					
						
							| 
									
										
										
										
											2021-04-06 14:49:15 +02:00
										 |  |  |         '--network', 'host', | 
					
						
							| 
									
										
										
										
											2021-02-15 10:08:19 +01:00
										 |  |  |         '--push', | 
					
						
							| 
									
										
										
										
											2021-04-26 11:02:09 +02:00
										 |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2021-05-23 02:41:02 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       12, | 
					
						
							| 
									
										
										
										
											2021-05-23 02:41:02 +02:00
										 |  |  |       '0.4.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['labels', 'org.opencontainers.image.title=filter_results_top_n\norg.opencontainers.image.description=Reference implementation of operation "filter results (top-n)"'], | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  |         ['outputs', 'type=local,dest=./release-out'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2021-05-23 02:41:02 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							|  |  |  |         '--label', 'org.opencontainers.image.title=filter_results_top_n', | 
					
						
							|  |  |  |         '--label', 'org.opencontainers.image.description=Reference implementation of operation "filter results (top-n)"', | 
					
						
							|  |  |  |         '--output', 'type=local,dest=./release-out', | 
					
						
							|  |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2021-08-16 23:44:13 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |       13, | 
					
						
							| 
									
										
										
										
											2021-08-16 23:44:13 +02:00
										 |  |  |       '0.6.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['tag', 'localhost:5000/name/app:latest'], | 
					
						
							|  |  |  |         ['file', './test/Dockerfile'], | 
					
						
							| 
									
										
										
										
											2022-01-31 11:47:45 +01:00
										 |  |  |         ['add-hosts', 'docker:10.180.0.1,foo:10.0.0.1'], | 
					
						
							| 
									
										
										
										
											2021-08-16 23:44:13 +02:00
										 |  |  |         ['network', 'host'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'true'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['pull', 'false'], | 
					
						
							| 
									
										
										
										
											2021-08-16 23:44:13 +02:00
										 |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2022-01-31 11:47:45 +01:00
										 |  |  |         '--add-host', 'docker:10.180.0.1', | 
					
						
							|  |  |  |         '--add-host', 'foo:10.0.0.1', | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |         '--file', './test/Dockerfile', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							|  |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2021-08-16 23:44:13 +02:00
										 |  |  |         '--network', 'host', | 
					
						
							|  |  |  |         '--push', | 
					
						
							|  |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2021-08-16 23:44:13 +02:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |     [ | 
					
						
							|  |  |  |       14, | 
					
						
							|  |  |  |       '0.7.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['file', './test/Dockerfile'], | 
					
						
							| 
									
										
										
										
											2022-01-31 11:47:45 +01:00
										 |  |  |         ['add-hosts', 'docker:10.180.0.1\nfoo:10.0.0.1'], | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         ['cgroup-parent', 'foo'], | 
					
						
							|  |  |  |         ['shm-size', '2g'], | 
					
						
							|  |  |  |         ['ulimit', `nofile=1024:1024
 | 
					
						
							|  |  |  | nproc=3`],
 | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2022-01-30 18:33:31 +01:00
										 |  |  |         '--add-host', 'docker:10.180.0.1', | 
					
						
							| 
									
										
										
										
											2022-01-31 11:47:45 +01:00
										 |  |  |         '--add-host', 'foo:10.0.0.1', | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         '--cgroup-parent', 'foo', | 
					
						
							|  |  |  |         '--file', './test/Dockerfile', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         '--shm-size', '2g', | 
					
						
							|  |  |  |         '--ulimit', 'nofile=1024:1024', | 
					
						
							|  |  |  |         '--ulimit', 'nproc=3', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2021-11-16 07:19:27 +01:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2021-12-28 00:49:32 +01:00
										 |  |  |     [ | 
					
						
							|  |  |  |       15, | 
					
						
							|  |  |  |       '0.7.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '{{defaultContext}}:docker'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							|  |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master:docker' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2021-12-28 00:49:32 +01:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2022-08-03 14:38:56 +02:00
										 |  |  |     [ | 
					
						
							|  |  |  |       16, | 
					
						
							|  |  |  |       '0.8.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['github-token', 'abcdefghijklmno0123456789'], | 
					
						
							|  |  |  |         ['context', '{{defaultContext}}:subdir'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         '--secret', `id=GIT_AUTH_TOKEN,src=${tmpName}`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         'https://github.com/docker/build-push-action.git#refs/heads/master:subdir' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       17, | 
					
						
							|  |  |  |       '0.8.2', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['provenance', 'true'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							|  |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       18, | 
					
						
							|  |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,mode=min,inline-only=true,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       19, | 
					
						
							|  |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['provenance', 'true'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       20, | 
					
						
							|  |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['provenance', 'mode=max'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,mode=max,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       21, | 
					
						
							|  |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['provenance', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |         '--attest', 'type=provenance,disabled=true', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       22, | 
					
						
							|  |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['provenance', 'builder-id=foo'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |         '--attest', 'type=provenance,builder-id=foo', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-13 12:57:15 +01:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2023-01-27 14:06:06 +01:00
										 |  |  |     [ | 
					
						
							|  |  |  |       23, | 
					
						
							|  |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['outputs', 'type=docker'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-01-27 14:06:06 +01:00
										 |  |  |         "--output", 'type=docker', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-01-27 14:06:06 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-27 14:06:06 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       24, | 
					
						
							|  |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'true'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-06-13 10:52:03 +02:00
										 |  |  |         '--load', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-06-13 10:52:03 +02:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-06-13 10:52:03 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       25, | 
					
						
							|  |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['build-args', `FOO=bar#baz`], | 
					
						
							|  |  |  |         ['load', 'true'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							|  |  |  |         '--build-arg', 'FOO=bar#baz', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-09-26 16:34:10 +02:00
										 |  |  |         '--load', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-09-26 16:34:10 +02:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-09-26 16:34:10 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |       26, | 
					
						
							| 
									
										
										
										
											2023-09-26 16:34:10 +02:00
										 |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['load', 'true'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['secret-envs', `MY_SECRET=MY_SECRET_ENV
 | 
					
						
							|  |  |  | ANOTHER_SECRET=ANOTHER_SECRET_ENV`]
 | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							|  |  |  |         '--secret', 'id=MY_SECRET,env=MY_SECRET_ENV', | 
					
						
							|  |  |  |         '--secret', 'id=ANOTHER_SECRET,env=ANOTHER_SECRET_ENV', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-09-26 16:34:10 +02:00
										 |  |  |         '--load', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-09-26 16:34:10 +02:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-09-26 16:34:10 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |       27, | 
					
						
							| 
									
										
										
										
											2023-09-26 16:34:10 +02:00
										 |  |  |       '0.10.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['load', 'true'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['secret-envs', 'MY_SECRET=MY_SECRET_ENV,ANOTHER_SECRET=ANOTHER_SECRET_ENV'] | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							|  |  |  |         '--secret', 'id=MY_SECRET,env=MY_SECRET_ENV', | 
					
						
							|  |  |  |         '--secret', 'id=ANOTHER_SECRET,env=ANOTHER_SECRET_ENV', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |         '--load', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-01-27 14:06:06 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-01-27 14:06:06 +01:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2023-10-24 07:23:44 +02:00
										 |  |  |     [ | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |       28, | 
					
						
							| 
									
										
										
										
											2023-10-24 07:23:44 +02:00
										 |  |  |       '0.11.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['annotations', 'example1=www\nindex:example2=xxx\nmanifest:example3=yyy\nmanifest-descriptor[linux/amd64]:example4=zzz'], | 
					
						
							|  |  |  |         ['outputs', 'type=local,dest=./release-out'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							|  |  |  |         '--output', 'type=local,dest=./release-out', | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,mode=min,inline-only=true,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-10-24 07:23:44 +02:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2023-10-24 07:23:44 +02:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |       29, | 
					
						
							| 
									
										
										
										
											2023-10-24 07:23:44 +02:00
										 |  |  |       '0.12.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['annotations', 'example1=www\nindex:example2=xxx\nmanifest:example3=yyy\nmanifest-descriptor[linux/amd64]:example4=zzz'], | 
					
						
							|  |  |  |         ['outputs', 'type=local,dest=./release-out'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							|  |  |  |         '--annotation', 'example1=www', | 
					
						
							|  |  |  |         '--annotation', 'index:example2=xxx', | 
					
						
							|  |  |  |         '--annotation', 'manifest:example3=yyy', | 
					
						
							|  |  |  |         '--annotation', 'manifest-descriptor[linux/amd64]:example4=zzz', | 
					
						
							|  |  |  |         '--output', 'type=local,dest=./release-out', | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,mode=min,inline-only=true,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2024-03-06 15:25:57 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2024-03-06 15:25:57 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |       30, | 
					
						
							| 
									
										
										
										
											2024-03-06 15:25:57 +01:00
										 |  |  |       '0.12.0', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['outputs', `type=image,"name=localhost:5000/name/app:latest,localhost:5000/name/app:foo",push-by-digest=true,name-canonical=true,push=true`], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-03-06 15:25:57 +01:00
										 |  |  |         "--output", `type=image,"name=localhost:5000/name/app:latest,localhost:5000/name/app:foo",push-by-digest=true,name-canonical=true,push=true`, | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,mode=min,inline-only=true,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2023-10-24 07:23:44 +02:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       31, | 
					
						
							|  |  |  |       '0.13.1', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['provenance', 'mode=max'], | 
					
						
							|  |  |  |         ['sbom', 'true'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,mode=max,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |         '--attest', `type=sbom,disabled=false`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       32, | 
					
						
							|  |  |  |       '0.13.1', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['attests', 'type=provenance,mode=min'], | 
					
						
							|  |  |  |         ['provenance', 'mode=max'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,mode=max,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       33, | 
					
						
							|  |  |  |       '0.13.1', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'], | 
					
						
							|  |  |  |         ['attests', 'type=provenance,mode=min'], | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							| 
									
										
										
										
											2024-06-10 15:05:57 +02:00
										 |  |  |         '--attest', `type=provenance,mode=min,builder-id=https://github.com/docker/build-push-action/actions/runs/123456789/attempts/1`, | 
					
						
							| 
									
										
										
										
											2024-05-14 14:11:32 +02:00
										 |  |  |         '--metadata-file', metadataJson, | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |         '.' | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |       ], | 
					
						
							|  |  |  |       undefined | 
					
						
							|  |  |  |     ], | 
					
						
							|  |  |  |     [ | 
					
						
							|  |  |  |       34, | 
					
						
							|  |  |  |       '0.13.1', | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['context', '.'], | 
					
						
							|  |  |  |         ['load', 'false'], | 
					
						
							|  |  |  |         ['no-cache', 'false'], | 
					
						
							|  |  |  |         ['push', 'false'], | 
					
						
							|  |  |  |         ['pull', 'false'] | 
					
						
							|  |  |  |       ]), | 
					
						
							|  |  |  |       [ | 
					
						
							|  |  |  |         'build', | 
					
						
							|  |  |  |         '--iidfile', imageIDFilePath, | 
					
						
							|  |  |  |         '--metadata-file', metadataJson, | 
					
						
							|  |  |  |         '.' | 
					
						
							|  |  |  |       ], | 
					
						
							|  |  |  |       new Map<string, string>([ | 
					
						
							|  |  |  |         ['BUILDX_NO_DEFAULT_ATTESTATIONS', '1'] | 
					
						
							|  |  |  |       ]) | 
					
						
							| 
									
										
										
										
											2024-03-26 15:31:37 +01:00
										 |  |  |     ], | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |   ])( | 
					
						
							| 
									
										
										
										
											2021-11-16 05:19:44 +01:00
										 |  |  |     '[%d] given %p with %p as inputs, returns %p', | 
					
						
							| 
									
										
										
										
											2025-03-28 11:16:09 +01:00
										 |  |  |     async (num: number, buildxVersion: string, inputs: Map<string, string>, expected: Array<string>, envs: Map<string, string> | undefined) => { | 
					
						
							|  |  |  |       if (envs) { | 
					
						
							|  |  |  |         envs.forEach((value: string, name: string) => { | 
					
						
							|  |  |  |           process.env[name] = value; | 
					
						
							|  |  |  |         }); | 
					
						
							|  |  |  |       } | 
					
						
							| 
									
										
										
										
											2022-03-15 21:59:52 +01:00
										 |  |  |       inputs.forEach((value: string, name: string) => { | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |         setInput(name, value); | 
					
						
							|  |  |  |       }); | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |       const toolkit = new Toolkit(); | 
					
						
							|  |  |  |       jest.spyOn(Buildx.prototype, 'version').mockImplementation(async (): Promise<string> => { | 
					
						
							|  |  |  |         return buildxVersion; | 
					
						
							|  |  |  |       }); | 
					
						
							| 
									
										
										
										
											2023-04-17 01:32:21 +02:00
										 |  |  |       const inp = await context.getInputs(); | 
					
						
							| 
									
										
										
										
											2023-02-20 11:11:15 +01:00
										 |  |  |       const res = await context.getArgs(inp, toolkit); | 
					
						
							| 
									
										
										
										
											2020-10-19 21:17:06 +02:00
										 |  |  |       expect(res).toEqual(expected); | 
					
						
							|  |  |  |     } | 
					
						
							|  |  |  |   ); | 
					
						
							|  |  |  | }); | 
					
						
							| 
									
										
										
										
											2020-08-17 02:32:27 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-06-22 17:25:52 +02:00
										 |  |  | // See: https://github.com/actions/toolkit/blob/a1b068ec31a042ff1e10a522d8fdf0b8869d53ca/packages/core/src/core.ts#L89
 | 
					
						
							| 
									
										
										
										
											2020-08-17 02:32:27 +02:00
										 |  |  | function getInputName(name: string): string { | 
					
						
							|  |  |  |   return `INPUT_${name.replace(/ /g, '_').toUpperCase()}`; | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | function setInput(name: string, value: string): void { | 
					
						
							|  |  |  |   process.env[getInputName(name)] = value; | 
					
						
							|  |  |  | } |