@@ -698,14 +698,16 @@ jobs:
698698 driver-opts : image=${{ env.BUILDKIT_IMAGE }}
699699 -
700700 name : Create manifest
701- if : ${{ inputs.push && inputs. output == 'image' }}
701+ if : ${{ inputs.output == 'image' }}
702702 uses : actions/github-script@v8
703703 env :
704+ INPUT_PUSH : ${{ inputs.push }}
704705 INPUT_IMAGE-NAMES : ${{ inputs.meta-images }}
705706 INPUT_TAG-NAMES : ${{ steps.meta.outputs.tag-names }}
706707 INPUT_BUILD-OUTPUTS : ${{ toJSON(needs.build.outputs) }}
707708 with :
708709 script : |
710+ const inpPush = core.getBooleanInput('push');
709711 const inpImageNames = core.getMultilineInput('image-names');
710712 const inpTagNames = core.getMultilineInput('tag-names');
711713 const inpBuildOutputs = JSON.parse(core.getInput('build-outputs'));
@@ -729,13 +731,19 @@ jobs:
729731 for (const digest of digests) {
730732 createArgs.push(digest);
731733 }
732- await exec.getExecOutput('docker', createArgs, {
733- ignoreReturnCode: true
734- }).then(res => {
735- if (res.stderr.length > 0 && res.exitCode != 0) {
736- throw new Error(res.stderr);
737- }
738- });
734+ if (inpPush) {
735+ await exec.getExecOutput('docker', createArgs, {
736+ ignoreReturnCode: true
737+ }).then(res => {
738+ if (res.stderr.length > 0 && res.exitCode != 0) {
739+ throw new Error(res.stderr);
740+ }
741+ });
742+ } else {
743+ await core.group(`Generated imagetools create command for ${imageName}`, async () => {
744+ core.info(`docker ${createArgs.join(' ')}`);
745+ });
746+ }
739747 }
740748 -
741749 name : Set outputs
0 commit comments