Skip to content

Commit 9716e42

Browse files
authored
Merge pull request #387 from crazy-max/rm-legacy-export
remove legacy export-build tool support
2 parents df378f3 + f04bdcc commit 9716e42

5 files changed

Lines changed: 5 additions & 43 deletions

File tree

.github/workflows/ci.yml

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -652,35 +652,6 @@ jobs:
652652
env:
653653
DOCKER_BUILD_RECORD_RETENTION_DAYS: ${{ matrix.days }}
654654

655-
export-legacy:
656-
runs-on: ubuntu-latest
657-
strategy:
658-
fail-fast: false
659-
matrix:
660-
legacy:
661-
- false
662-
- true
663-
steps:
664-
-
665-
name: Checkout
666-
uses: actions/checkout@v6
667-
-
668-
name: Set up Docker Buildx
669-
uses: docker/setup-buildx-action@v3
670-
with:
671-
version: ${{ inputs.buildx-version || env.BUILDX_VERSION }}
672-
driver-opts: |
673-
image=${{ inputs.buildkit-image || env.BUILDKIT_IMAGE }}
674-
-
675-
name: Build
676-
uses: ./
677-
with:
678-
files: |
679-
./test/config.hcl
680-
targets: app
681-
env:
682-
DOCKER_BUILD_EXPORT_LEGACY: ${{ matrix.legacy }}
683-
684655
checks:
685656
runs-on: ubuntu-latest
686657
strategy:

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,6 @@ The following outputs are available
231231
| `DOCKER_BUILD_SUMMARY` | Bool | `true` | If `false`, [build summary](https://docs.docker.com/build/ci/github-actions/build-summary/) generation is disabled |
232232
| `DOCKER_BUILD_RECORD_UPLOAD` | Bool | `true` | If `false`, build record upload as [GitHub artifact](https://docs.github.com/en/actions/using-workflows/storing-workflow-data-as-artifacts) is disabled |
233233
| `DOCKER_BUILD_RECORD_RETENTION_DAYS` | Number | | Duration after which build record artifact will expire in days. Defaults to repository/org [retention settings](https://docs.github.com/en/actions/learn-github-actions/usage-limits-billing-and-administration#artifact-and-log-retention-policy) if unset or `0` |
234-
| `DOCKER_BUILD_EXPORT_LEGACY` | Bool | `false` | If `true`, exports build using legacy export-build tool instead of [`buildx history export` command](https://docs.docker.com/reference/cli/docker/buildx/history/export/) |
235234

236235
## Subactions
237236

dist/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main.ts

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -215,8 +215,8 @@ actionsToolkit.run(
215215
core.info(`Build summary skipped for ${inputs.call} subrequest`);
216216
} else if (GitHub.isGHES) {
217217
core.info('Build summary is not yet supported on GHES');
218-
} else if (!(await toolkit.buildx.versionSatisfies('>=0.13.0'))) {
219-
core.info('Build summary requires Buildx >= 0.13.0');
218+
} else if (!(await toolkit.buildx.versionSatisfies('>=0.23.0'))) {
219+
core.info('Build summary requires Buildx >= 0.23.0');
220220
} else if (refs.length == 0) {
221221
core.info('Build summary requires at least one build reference');
222222
} else {
@@ -242,8 +242,7 @@ actionsToolkit.run(
242242

243243
const buildxHistory = new BuildxHistory();
244244
const exportRes = await buildxHistory.export({
245-
refs: stateHelper.buildRefs,
246-
useContainer: buildExportLegacy()
245+
refs: stateHelper.buildRefs
247246
});
248247
core.info(`Build records written to ${exportRes.dockerbuildFilename} (${Util.formatFileSize(exportRes.dockerbuildSize)})`);
249248

@@ -341,10 +340,3 @@ function buildRecordRetentionDays(): number | undefined {
341340
return res;
342341
}
343342
}
344-
345-
function buildExportLegacy(): boolean {
346-
if (process.env.DOCKER_BUILD_EXPORT_LEGACY) {
347-
return Util.parseBool(process.env.DOCKER_BUILD_EXPORT_LEGACY);
348-
}
349-
return false;
350-
}

0 commit comments

Comments
 (0)