Skip to content

Commit 667cb22

Browse files
committed
DOCKER_BUILD_NO_SUMMARY env to disable summary
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
1 parent d880b19 commit 667cb22

File tree

3 files changed

+34
-0
lines changed

3 files changed

+34
-0
lines changed

.github/workflows/ci.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1344,3 +1344,26 @@ jobs:
13441344
name: Check docker
13451345
run: |
13461346
docker image inspect localhost:5000/name/app:latest
1347+
1348+
disable-summary:
1349+
runs-on: ubuntu-latest
1350+
steps:
1351+
-
1352+
name: Checkout
1353+
uses: actions/checkout@v4
1354+
with:
1355+
path: action
1356+
-
1357+
name: Set up Docker Buildx
1358+
uses: docker/setup-buildx-action@v3
1359+
with:
1360+
version: ${{ inputs.buildx-version || env.BUILDX_VERSION }}
1361+
driver-opts: |
1362+
image=${{ inputs.buildkit-image || env.BUILDKIT_IMAGE }}
1363+
-
1364+
name: Build
1365+
uses: ./action
1366+
with:
1367+
file: ./test/Dockerfile
1368+
env:
1369+
DOCKER_BUILD_NO_SUMMARY: true

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ ___
3737
* [Customizing](#customizing)
3838
* [inputs](#inputs)
3939
* [outputs](#outputs)
40+
* [environment variables](#environment-variables)
4041
* [Troubleshooting](#troubleshooting)
4142
* [Contributing](#contributing)
4243

@@ -256,6 +257,12 @@ The following outputs are available:
256257
| `digest` | String | Image digest |
257258
| `metadata` | JSON | Build result metadata |
258259

260+
### environment variables
261+
262+
| Name | Type | Description |
263+
|---------------------------|------|-------------------------------------------------------------------------------------------------------------------|
264+
| `DOCKER_BUILD_NO_SUMMARY` | Bool | If `true`, [build summary](https://docs.docker.com/build/ci/github-actions/build-summary/) generation is disabled |
265+
259266
## Troubleshooting
260267

261268
See [TROUBLESHOOTING.md](TROUBLESHOOTING.md)

src/main.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,10 @@ actionsToolkit.run(
141141
async () => {
142142
if (stateHelper.buildRef.length > 0) {
143143
await core.group(`Generating build summary`, async () => {
144+
if (process.env.DOCKER_BUILD_NO_SUMMARY && Util.parseBool(process.env.DOCKER_BUILD_NO_SUMMARY)) {
145+
core.info('Summary disabled');
146+
return;
147+
}
144148
try {
145149
const buildxHistory = new BuildxHistory();
146150
const exportRes = await buildxHistory.export({

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy