Skip to content
This repository was archived by the owner on Aug 5, 2025. It is now read-only.

Commit d73dffb

Browse files
committed
Remove unnecessary CentOS references
1 parent 072bf85 commit d73dffb

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

.github/workflows/history.sh

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,9 @@ set -Eeuo pipefail
66
docker image history --no-trunc --format '{{ .CreatedBy }}' "$@" \
77
| tac \
88
| sed -r 's!^/bin/sh[[:space:]]+-c[[:space:]]+(#[(]nop[)][[:space:]]+)?!!' \
9-
| awk '
10-
# ignore the first ADD of the base image (base image changes unnecessarily break our diffs)
11-
NR == 1 && $1 == "ADD" && $4 == "/" { next }
12-
# TODO consider instead just removing the checksum in $3
13-
14-
# ignore obviously "centos" LABEL instructions (include a timestamp, so base image changes unnecessarily break our diffs)
15-
$1 == "LABEL" && / org.opencontainers.image.vendor=CentOS | org.label-schema.vendor=CentOS / { next }
16-
17-
# just ignore the default CentOS CMD value (not relevant to our needs)
18-
$0 == "CMD [\"/bin/bash\"]" { next }
9+
| gawk '
10+
# munge the checksum of the first ADD of the base image (base image changes unnecessarily break our diffs)
11+
NR == 1 && $1 == "ADD" && $4 == "/" { $2 = "-" }
1912
2013
# ignore the contents of certain copies (notoriously unreliable hashes because they often contain timestamps)
2114
$1 == "COPY" && ($4 == "/usr/share/elasticsearch" || $4 ~ /^\/opt\/jdk-/) { gsub(/:[0-9a-f]{64}$/, ":filtered-content-hash", $2) }

0 commit comments

Comments
 (0)