mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-21 19:01:49 +00:00
Merge pull request #95567 from claudiubelu/test-images/linux-busybox
test images: Mirrors dockerhub images to staging
This commit is contained in:
commit
11ab887ccd
@ -1,3 +1,8 @@
|
||||
linux/amd64=busybox:1.29
|
||||
linux/arm=arm32v6/busybox:1.29
|
||||
linux/arm64=arm64v8/busybox:1.29
|
||||
linux/ppc64le=ppc64le/busybox:1.29
|
||||
linux/s390x=s390x/busybox:1.29
|
||||
windows/amd64/1809=mcr.microsoft.com/windows/nanoserver:1809
|
||||
windows/amd64/1903=mcr.microsoft.com/windows/nanoserver:1903
|
||||
windows/amd64/1909=mcr.microsoft.com/windows/nanoserver:1909
|
||||
|
17
test/images/busybox/Dockerfile
Normal file
17
test/images/busybox/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
# Copyright 2020 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
1
test/images/glusterdynamic-provisioner/BASEIMAGE
Normal file
1
test/images/glusterdynamic-provisioner/BASEIMAGE
Normal file
@ -0,0 +1 @@
|
||||
linux/amd64=docker.io/gluster/glusterdynamic-provisioner:v1.0
|
17
test/images/glusterdynamic-provisioner/Dockerfile
Normal file
17
test/images/glusterdynamic-provisioner/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
# Copyright 2020 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
1
test/images/glusterdynamic-provisioner/VERSION
Normal file
1
test/images/glusterdynamic-provisioner/VERSION
Normal file
@ -0,0 +1 @@
|
||||
v1.0
|
1
test/images/httpd-new/ALIAS
Normal file
1
test/images/httpd-new/ALIAS
Normal file
@ -0,0 +1 @@
|
||||
httpd
|
5
test/images/httpd-new/BASEIMAGE
Normal file
5
test/images/httpd-new/BASEIMAGE
Normal file
@ -0,0 +1,5 @@
|
||||
linux/amd64=httpd:2.4.39-alpine
|
||||
linux/arm=arm32v6/httpd:2.4.39-alpine
|
||||
linux/arm64=arm64v8/httpd:2.4.39-alpine
|
||||
linux/ppc64le=ppc64le/httpd:2.4.39-alpine
|
||||
linux/s390x=s390x/httpd:2.4.39-alpine
|
17
test/images/httpd-new/Dockerfile
Normal file
17
test/images/httpd-new/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
# Copyright 2020 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
1
test/images/httpd-new/VERSION
Normal file
1
test/images/httpd-new/VERSION
Normal file
@ -0,0 +1 @@
|
||||
2.4.39-alpine
|
5
test/images/httpd/BASEIMAGE
Normal file
5
test/images/httpd/BASEIMAGE
Normal file
@ -0,0 +1,5 @@
|
||||
linux/amd64=httpd:2.4.38-alpine
|
||||
linux/arm=arm32v6/httpd:2.4.38-alpine
|
||||
linux/arm64=arm64v8/httpd:2.4.38-alpine
|
||||
linux/ppc64le=ppc64le/httpd:2.4.38-alpine
|
||||
linux/s390x=s390x/httpd:2.4.38-alpine
|
17
test/images/httpd/Dockerfile
Normal file
17
test/images/httpd/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
# Copyright 2020 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
1
test/images/httpd/VERSION
Normal file
1
test/images/httpd/VERSION
Normal file
@ -0,0 +1 @@
|
||||
2.4.38-alpine
|
@ -89,16 +89,26 @@ getBaseImage() {
|
||||
# arm64, ppc64le, s390x
|
||||
build() {
|
||||
image=$1
|
||||
img_folder=$1
|
||||
output_type=$2
|
||||
docker_version_check
|
||||
|
||||
if [[ -f ${image}/BASEIMAGE ]]; then
|
||||
if [[ -f "${img_folder}/BASEIMAGE" ]]; then
|
||||
os_archs=$(listOsArchs "$image")
|
||||
else
|
||||
# prepend linux/ to the QEMUARCHS items.
|
||||
os_archs=$(printf 'linux/%s\n' "${!QEMUARCHS[@]}")
|
||||
fi
|
||||
|
||||
# image tag
|
||||
TAG=$(<"${img_folder}/VERSION")
|
||||
|
||||
alias_name="$(cat "${img_folder}/ALIAS" 2>/dev/null || true)"
|
||||
if [[ -n "${alias_name}" ]]; then
|
||||
echo "Found an alias for '${image}'. Building / tagging image as '${alias_name}.'"
|
||||
image="${alias_name}"
|
||||
fi
|
||||
|
||||
kube::util::ensure-gnu-sed
|
||||
|
||||
for os_arch in ${os_archs}; do
|
||||
@ -116,15 +126,13 @@ build() {
|
||||
temp_dir=$(mktemp -d "${KUBE_ROOT}"/_tmp/test-images-build.XXXXXX)
|
||||
kube::util::trap_add "rm -rf ${temp_dir}" EXIT
|
||||
|
||||
cp -r "${image}"/* "${temp_dir}"
|
||||
if [[ -f ${image}/Makefile ]]; then
|
||||
cp -r "${img_folder}"/* "${temp_dir}"
|
||||
if [[ -f ${img_folder}/Makefile ]]; then
|
||||
# make bin will take care of all the prerequisites needed
|
||||
# for building the docker image
|
||||
make -C "${image}" bin OS="${os_name}" ARCH="${arch}" TARGET="${temp_dir}"
|
||||
make -C "${img_folder}" bin OS="${os_name}" ARCH="${arch}" TARGET="${temp_dir}"
|
||||
fi
|
||||
pushd "${temp_dir}"
|
||||
# image tag
|
||||
TAG=$(<VERSION)
|
||||
|
||||
# NOTE(claudiub): Some Windows images might require their own Dockerfile
|
||||
# while simpler ones will not. If we're building for Windows, check if
|
||||
@ -190,6 +198,13 @@ push() {
|
||||
os_archs=$(printf 'linux/%s\n' "${!QEMUARCHS[@]}")
|
||||
fi
|
||||
|
||||
pushd "${image}"
|
||||
alias_name="$(cat ALIAS 2>/dev/null || true)"
|
||||
if [[ -n "${alias_name}" ]]; then
|
||||
echo "Found an alias for '${image}'. Pushing image as '${alias_name}.'"
|
||||
image="${alias_name}"
|
||||
fi
|
||||
|
||||
kube::util::ensure-gnu-sed
|
||||
|
||||
# reset manifest list; needed in case multiple images are being built / pushed.
|
||||
@ -223,6 +238,7 @@ push() {
|
||||
"${HOME}/.docker/manifests/${manifest_image_folder}/${manifest_image_folder}-${suffix}"
|
||||
fi
|
||||
done
|
||||
popd
|
||||
docker manifest push --purge "${REGISTRY}/${image}:${TAG}"
|
||||
}
|
||||
|
||||
|
1
test/images/nginx-new/ALIAS
Normal file
1
test/images/nginx-new/ALIAS
Normal file
@ -0,0 +1 @@
|
||||
nginx
|
5
test/images/nginx-new/BASEIMAGE
Normal file
5
test/images/nginx-new/BASEIMAGE
Normal file
@ -0,0 +1,5 @@
|
||||
linux/amd64=nginx:1.15-alpine
|
||||
linux/arm=arm32v6/nginx:1.15-alpine
|
||||
linux/arm64=arm64v8/nginx:1.15-alpine
|
||||
linux/ppc64le=ppc64le/nginx:1.15-alpine
|
||||
linux/s390x=s390x/nginx:1.15-alpine
|
17
test/images/nginx-new/Dockerfile
Normal file
17
test/images/nginx-new/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
# Copyright 2020 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
1
test/images/nginx-new/VERSION
Normal file
1
test/images/nginx-new/VERSION
Normal file
@ -0,0 +1 @@
|
||||
1.15-alpine
|
5
test/images/nginx/BASEIMAGE
Normal file
5
test/images/nginx/BASEIMAGE
Normal file
@ -0,0 +1,5 @@
|
||||
linux/amd64=nginx:1.14-alpine
|
||||
linux/arm=arm32v6/nginx:1.14-alpine
|
||||
linux/arm64=arm64v8/nginx:1.14-alpine
|
||||
linux/ppc64le=ppc64le/nginx:1.14-alpine
|
||||
linux/s390x=s390x/nginx:1.14-alpine
|
17
test/images/nginx/Dockerfile
Normal file
17
test/images/nginx/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
# Copyright 2020 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
1
test/images/nginx/VERSION
Normal file
1
test/images/nginx/VERSION
Normal file
@ -0,0 +1 @@
|
||||
1.14-alpine
|
5
test/images/perl/BASEIMAGE
Normal file
5
test/images/perl/BASEIMAGE
Normal file
@ -0,0 +1,5 @@
|
||||
linux/amd64=perl:5.26
|
||||
linux/arm=arm32v7/perl:5.26
|
||||
linux/arm64=arm64v8/perl:5.26
|
||||
linux/ppc64le=ppc64le/perl:5.26
|
||||
linux/s390x=s390x/perl:5.26
|
17
test/images/perl/Dockerfile
Normal file
17
test/images/perl/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
# Copyright 2020 The Kubernetes Authors.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# NOTE(claudiub): Noop. We're just mirroring the image to staging.
|
||||
ARG BASEIMAGE
|
||||
FROM $BASEIMAGE
|
1
test/images/perl/VERSION
Normal file
1
test/images/perl/VERSION
Normal file
@ -0,0 +1 @@
|
||||
5.26
|
Loading…
Reference in New Issue
Block a user