mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-21 10:51:29 +00:00
test images: Adds image labels by default
Adds the "image_version", "commit_id", "git_url" to the image labels.
This commit is contained in:
parent
f6c2068623
commit
05cfbecab9
@ -15,5 +15,3 @@
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
||||
|
||||
LABEL image_version="1.29-1"
|
||||
|
@ -92,5 +92,4 @@ ENV PATH="C:\dig\;C:\bin;C:\curl;C:\Windows\System32;C:\Windows;C:\Program Files
|
||||
# Persist %PSCORE% ENV variable for user convenience
|
||||
PSCORE="C:\Program Files\PowerShell\pwsh.exe"
|
||||
|
||||
LABEL image_version="1.29-1"
|
||||
ENTRYPOINT ["cmd.exe", "/s", "/c"]
|
||||
|
@ -15,5 +15,3 @@
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
||||
|
||||
LABEL image_version="v1.0"
|
||||
|
@ -15,5 +15,3 @@
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
||||
|
||||
LABEL image_version="2.4.39-1"
|
||||
|
@ -43,5 +43,4 @@ ENV PATH="C:\dig;C:\bin;C:\curl;C:\Windows\System32;C:\Windows;C:\Program Files\
|
||||
|
||||
USER ContainerAdministrator
|
||||
EXPOSE 80
|
||||
LABEL image_version="2.4.39-1"
|
||||
ENTRYPOINT ["C:/usr/local/apache2/bin/httpd.exe"]
|
||||
|
@ -15,5 +15,3 @@
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
||||
|
||||
LABEL image_version="2.4.38-1"
|
||||
|
@ -43,5 +43,4 @@ ENV PATH="C:\dig;C:\bin;C:\curl;C:\Windows\System32;C:\Windows;C:\Program Files\
|
||||
|
||||
USER ContainerAdministrator
|
||||
EXPOSE 80
|
||||
LABEL image_version="2.4.39-1"
|
||||
ENTRYPOINT ["C:/usr/local/apache2/bin/httpd.exe"]
|
||||
|
@ -36,6 +36,7 @@ source "${KUBE_ROOT}/hack/lib/util.sh"
|
||||
# Mapping of go ARCH to actual architectures shipped part of multiarch/qemu-user-static project
|
||||
declare -A QEMUARCHS=( ["amd64"]="x86_64" ["arm"]="arm" ["arm64"]="aarch64" ["ppc64le"]="ppc64le" ["s390x"]="s390x" )
|
||||
|
||||
GIT_COMMIT_ID=$(git log -1 --format=%h)
|
||||
windows_os_versions=(1809 1903 1909 2004 20H2)
|
||||
declare -A WINDOWS_OS_VERSIONS_MAP
|
||||
|
||||
@ -182,7 +183,9 @@ build() {
|
||||
|
||||
docker buildx build --progress=plain --no-cache --pull --output=type="${output_type}" --platform "${os_name}/${arch}" \
|
||||
--build-arg BASEIMAGE="${base_image}" --build-arg REGISTRY="${REGISTRY}" --build-arg OS_VERSION="${os_version}" \
|
||||
-t "${REGISTRY}/${image}:${TAG}-${suffix}" -f "${dockerfile_name}" .
|
||||
-t "${REGISTRY}/${image}:${TAG}-${suffix}" -f "${dockerfile_name}" \
|
||||
--label "image_version=${TAG}" --label "commit_id=${GIT_COMMIT_ID}" \
|
||||
--label "git_url=https://github.com/kubernetes/kubernetes/tree/${GIT_COMMIT_ID}/test/images/${img_folder}" .
|
||||
|
||||
popd
|
||||
done
|
||||
|
@ -15,5 +15,3 @@
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
||||
|
||||
LABEL image_version="1.15-1"
|
||||
|
@ -24,5 +24,4 @@ COPY --from=nginx-source /nginx /usr/share/nginx
|
||||
|
||||
USER ContainerAdministrator
|
||||
EXPOSE 80
|
||||
LABEL image_version="1.15-1"
|
||||
ENTRYPOINT ["/bin/sh", "-c", " cd /usr/share/nginx && ./nginx.exe"]
|
||||
|
@ -15,5 +15,3 @@
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
||||
|
||||
LABEL image_version="1.14-1"
|
||||
|
@ -24,5 +24,4 @@ COPY --from=nginx-source /nginx /usr/share/nginx
|
||||
|
||||
USER ContainerAdministrator
|
||||
EXPOSE 80
|
||||
LABEL image_version="1.14-1"
|
||||
ENTRYPOINT ["/bin/sh", "-c", " cd /usr/share/nginx && ./nginx.exe"]
|
||||
|
@ -15,5 +15,3 @@
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
||||
|
||||
LABEL image_version="5.26"
|
||||
|
@ -15,5 +15,3 @@
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
||||
|
||||
LABEL image_version="v1"
|
||||
|
Loading…
Reference in New Issue
Block a user