From: Sirisha Gopigiri Date: Tue, 8 Jun 2021 07:42:19 +0000 (+0530) Subject: Update sonobuoy kube-conformance docker images X-Git-Url: https://gerrit.akraino.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F13%2F4313%2F5;p=validation.git Update sonobuoy kube-conformance docker images This PS updates the conformance test case to use kube-conformance and sonobuoy-systemd-logs images from gcr.io repo instead of akraino repo. Signed-off-by: SirishaGopigiri Change-Id: If97ec80b06910b06e923a4765d0f5fa6d454650d --- diff --git a/.coafile b/.coafile index c472b5d..4d8a321 100644 --- a/.coafile +++ b/.coafile @@ -5,7 +5,6 @@ ignore = .tox/**, .git/**, .gitignore, .gitreview, - .gitmodules, **.sw?, **.orig diff --git a/.gitmodules b/.gitmodules deleted file mode 100644 index a51136e..0000000 --- a/.gitmodules +++ /dev/null @@ -1,8 +0,0 @@ -[submodule "sonobuoy-plugin-systemd-logs"] - path = docker/sonobuoy-plugin-systemd-logs/sonobuoy-plugin-systemd-logs - url = https://github.com/heptio/sonobuoy-plugin-systemd-logs - branch = master -[submodule "kube-conformance"] - path = docker/kube-conformance/kube-conformance - url = https://github.com/heptio/kube-conformance - branch = master diff --git a/docker/README.rst b/docker/README.rst index 0fff3ed..74cd787 100644 --- a/docker/README.rst +++ b/docker/README.rst @@ -199,84 +199,19 @@ Example (assuming the default variables have been utilized for building the imag The kube-conformance container ============================== -Building and pushing the container ----------------------------------- - -To build just the kube-conformance container, use the command: - -.. code-block:: console - - make kube-conformance-build [ REGISTRY= NAME=] - -To both build and push the container, use the command: - -.. code-block:: console - - make kube-conformance [ REGISTRY= NAME=] +The current kube-conformance image used is being pulled from k8s.gcr.io +based on the kubernetes version the cluster is running on. -Using the container -------------------- - -This is a standalone container able to launch Kubernetes end-to-end tests, -for the purposes of conformance testing. - -It is a thin wrapper around the `e2e.test` binary in the upstream Kubernetes -distribution, which drops results in a predetermined location for use as a -[Heptio Sonobuoy](https://github.com/heptio/sonobuoy) plugin. - -To learn more about conformance testing and its Sonobuoy integration, read the -[conformance guide](https://github.com/heptio/sonobuoy/blob/master/docs/conformance-testing.md). - -Example: - -.. code-block:: console - - docker run -ti akraino/validation:kube-conformance-v1.16 - -By default, the container will run the `run_e2e.sh` script. If you want to -enter the container, add */bin/sh* at the end of the command above - -Normally, this conainer is not used directly, but instead leveraged via -sonobuoy. +For more information refer to https://sonobuoy.io/docs/v0.50.0/ The sonobuoy-plugin-systemd-logs container ========================================== -Building and pushing the container ----------------------------------- - -To build just the sonobuoy-plugin-systemd-logs container, use the command: - -.. code-block:: console - - make sonobuoy-plugin-systemd-logs-build [ REGISTRY= NAME=] - -To both build and push the container, use the command: - -.. code-block:: console - - make sonobuoy-plugin-systemd-logs [ REGISTRY= NAME=] - -Using the container -------------------- - -This is a simple standalone container that gathers log information from -systemd, by chrooting into the node's filesystem and running `journalctl`. - -This container is used by [Heptio Sonobuoy](https://github.com/heptio/sonobuoy) -for gathering host logs in a Kubernetes cluster. - -Example: - -.. code-block:: console - - docker run -ti akraino/validation:sonobuoy-plugin-systemd-logs-latest +The current sonobuoy-plugin-systemd-logs image used is being pulled from +gcr.io/heptio-images repo with latest tag. -By default, the container will run the `get_systemd_logs.sh` script. If you -want to enter the container, add */bin/sh* at the end of the command above. +For more information refer to https://sonobuoy.io/docs/v0.50.0/ -Normally, this conainer is not used directly, but instead leveraged via -sonobuoy. The openstack container ======================= diff --git a/docker/k8s/Dockerfile b/docker/k8s/Dockerfile index 3296fdf..37baf3f 100644 --- a/docker/k8s/Dockerfile +++ b/docker/k8s/Dockerfile @@ -21,7 +21,7 @@ FROM golang:alpine3.10 as build # minor versions before. ARG SB_TAG=v0.16.1 # Determine the latest stable git tag at build time based on stable major version -ARG K8S_VER=1.16 +ARG K8S_VER=1.18 # Install dependencies COPY pip-requirements.txt /wheels/requirements/pip-requirements.txt diff --git a/docker/kube-conformance/Makefile b/docker/kube-conformance/Makefile deleted file mode 100644 index 1c0f7f0..0000000 --- a/docker/kube-conformance/Makefile +++ /dev/null @@ -1,34 +0,0 @@ -############################################################################## -# Copyright (c) 2019 AT&T, ENEA AB, Nokia and others # -# # -# Licensed under the Apache License, Version 2.0 (the "License"); # -# you maynot 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. # -############################################################################## - -export WORK_DIR?=$(TAG_PRE) -export KUBE_VERSION=1.16 -export TAG_VER=v$(KUBE_VERSION) - -.PHONY: .build -.build:: .submodules_patched - $(MAKE) -C $(TAG_PRE) e2e.test kubectl ginkgo - -.PHONY: all -all: push-image .push_manifest - -.PHONY: build -build: .build - -.PHONY: push-image -push-image: .push_image - -include ../build.mk diff --git a/docker/kube-conformance/kube-conformance b/docker/kube-conformance/kube-conformance deleted file mode 160000 index 9cdcb01..0000000 --- a/docker/kube-conformance/kube-conformance +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 9cdcb010918c815a51ac627ce68fa6f3165beaf8 diff --git a/docker/kube-conformance/patches/aarch64/0001-Dockerfile-Makefile-Add-AArch64-support.patch b/docker/kube-conformance/patches/aarch64/0001-Dockerfile-Makefile-Add-AArch64-support.patch deleted file mode 100644 index 770f6bd..0000000 --- a/docker/kube-conformance/patches/aarch64/0001-Dockerfile-Makefile-Add-AArch64-support.patch +++ /dev/null @@ -1,55 +0,0 @@ -From: Alexandru Avadanii -Date: Tue, 25 Jun 2019 17:59:13 +0200 -Subject: [PATCH] Dockerfile, Makefile: Add AArch64 support - -Signed-off-by: Alexandru Avadanii ---- - Dockerfile | 6 ++++-- - Makefile | 8 +++++--- - 2 files changed, 9 insertions(+), 5 deletions(-) - -diff --git a/Dockerfile b/Dockerfile -index 289ac88..102685d 100644 ---- a/Dockerfile -+++ b/Dockerfile -@@ -13,10 +13,12 @@ - # See the License for the specific language governing permissions and - # limitations under the License. - --FROM buildpack-deps:jessie-scm -+FROM arm64v8/buildpack-deps:jessie-scm - MAINTAINER Timothy St. Clair "tstclair@heptio.com" - --RUN apt-get update && apt-get -y --no-install-recommends install \ -+RUN echo 'Acquire::Check-Valid-Until "0";' > /etc/apt/apt.conf.d/10no--check-valid-until \ -+ && sed -i -e '/security/s/^/#/g' -e 's|deb.debian.org/debian|snapshot.debian.org/archive/debian/20190301T035241Z|g' /etc/apt/sources.list \ -+ && apt-get update && apt-get -y --no-install-recommends install \ - ca-certificates \ - && rm -rf /var/cache/apt/* \ - && rm -rf /var/lib/apt/lists/* -diff --git a/Makefile b/Makefile -index 4335cfd..bdaa52c 100644 ---- a/Makefile -+++ b/Makefile -@@ -29,6 +29,8 @@ is_root=$(filter 0,$(shell id -u)) - DOCKER?=$(if $(or $(in_docker_group),$(is_root)),docker,sudo docker) - DIR := ${CURDIR} - -+export KUBERNETES_SERVER_ARCH=arm64 -+ - .PHONY: all container getbins clean - - all: container -@@ -47,9 +49,9 @@ _cache/.getbins.$(kube_version_full).timestamp: - KUBERNETES_DOWNLOAD_TESTS=true \ - KUBERNETES_SKIP_CONFIRM=true ./kubernetes/cluster/get-kube-binaries.sh - mv _cache/$(kube_version_full)/kubernetes/cluster ./ -- mv _cache/$(kube_version_full)/kubernetes/platforms/linux/amd64/e2e.test ./ -- mv _cache/$(kube_version_full)/kubernetes/platforms/linux/amd64/ginkgo ./ -- mv _cache/$(kube_version_full)/kubernetes/platforms/linux/amd64/kubectl ./ -+ mv _cache/$(kube_version_full)/kubernetes/platforms/linux/arm64/e2e.test ./ -+ mv _cache/$(kube_version_full)/kubernetes/platforms/linux/arm64/ginkgo ./ -+ mv _cache/$(kube_version_full)/kubernetes/platforms/linux/arm64/kubectl ./ - touch $@ - - container: e2e.test kubectl ginkgo diff --git a/docker/sonobuoy-plugin-systemd-logs/Makefile b/docker/sonobuoy-plugin-systemd-logs/Makefile deleted file mode 100644 index 0af457a..0000000 --- a/docker/sonobuoy-plugin-systemd-logs/Makefile +++ /dev/null @@ -1,31 +0,0 @@ -############################################################################## -# Copyright (c) 2019 AT&T, ENEA AB, Nokia and others # -# # -# Licensed under the Apache License, Version 2.0 (the "License"); # -# you maynot 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. # -############################################################################## - -export WORK_DIR?=$(TAG_PRE) - -.PHONY: .build -.build:: .submodules_patched - -.PHONY: all -all: push-image .push_manifest - -.PHONY: build -build: .build - -.PHONY: push-image -push-image: .push_image - -include ../build.mk diff --git a/docker/sonobuoy-plugin-systemd-logs/patches/aarch64/0001-Dockerfile-AArch64-support.patch b/docker/sonobuoy-plugin-systemd-logs/patches/aarch64/0001-Dockerfile-AArch64-support.patch deleted file mode 100644 index 199e923..0000000 --- a/docker/sonobuoy-plugin-systemd-logs/patches/aarch64/0001-Dockerfile-AArch64-support.patch +++ /dev/null @@ -1,28 +0,0 @@ -From: Alexandru Avadanii -Date: Tue, 25 Jun 2019 17:45:29 +0200 -Subject: [PATCH] Dockerfile: AArch64 support - -Signed-off-by: Alexandru Avadanii ---- - Dockerfile | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - -diff --git a/Dockerfile b/Dockerfile -index 06d872c..687d541 100644 ---- a/Dockerfile -+++ b/Dockerfile -@@ -13,10 +13,12 @@ - # See the License for the specific language governing permissions and - # limitations under the License. - --FROM buildpack-deps:jessie-scm -+FROM arm64v8/buildpack-deps:jessie-scm - MAINTAINER Ken Simon "ken@heptio.com" - --RUN apt-get update && apt-get -y --no-install-recommends install \ -+RUN echo 'Acquire::Check-Valid-Until "0";' > /etc/apt/apt.conf.d/10no--check-valid-until \ -+ && sed -i -e '/security/s/^/#/g' -e 's|deb.debian.org/debian|snapshot.debian.org/archive/debian/20190301T035241Z|g' /etc/apt/sources.list \ -+ && apt-get update && apt-get -y --no-install-recommends install \ - ca-certificates \ - && rm -rf /var/cache/apt/* \ - && rm -rf /var/lib/apt/lists/* diff --git a/docker/sonobuoy-plugin-systemd-logs/sonobuoy-plugin-systemd-logs b/docker/sonobuoy-plugin-systemd-logs/sonobuoy-plugin-systemd-logs deleted file mode 160000 index f49e35d..0000000 --- a/docker/sonobuoy-plugin-systemd-logs/sonobuoy-plugin-systemd-logs +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f49e35d220772879aa057da7d103af35a21439b6 diff --git a/tests/k8s/conformance/conformance.robot b/tests/k8s/conformance/conformance.robot index c51f217..8cf83dd 100644 --- a/tests/k8s/conformance/conformance.robot +++ b/tests/k8s/conformance/conformance.robot @@ -39,10 +39,10 @@ ${LOG} ${LOG_PATH}${/}${SUITE_NAME.replace(' ','_')}.log &{SONOBUOY} path=gcr.io/heptio-images ... name=sonobuoy:v0.16.1 -&{E2E} path=akraino +&{E2E} path=k8s.gcr.io ... name=Actual value set dynamically -&{SYSTEMD_LOGS} path=akraino -... name=validation:sonobuoy-plugin-systemd-logs-latest +&{SYSTEMD_LOGS} path=gcr.io/heptio-images +... name=sonobuoy-plugin-systemd-logs:latest &{SONOBUOY_IMGS} sonobuoy=&{SONOBUOY} ... e2e=&{E2E} ... systemd_logs=&{SYSTEMD_LOGS} @@ -148,9 +148,11 @@ Define Images ${versions}= Convert String To JSON ${result.stdout} ${major}= Get Value From Json ${versions} $.serverVersion.major ${minor}= Get Value From Json ${versions} $.serverVersion.minor + ${gitVersion}= Get Value From Json ${versions} $.serverVersion.gitVersion ${major}= Get Regexp Matches ${major[0]} \\d+ ${minor}= Get Regexp Matches ${minor[0]} \\d+ - Set To Dictionary ${SONOBUOY_IMGS['e2e']} name=validation:kube-conformance-v${major[0]}.${minor[0]} + ${gitVersion}= Get Regexp Matches ${gitVersion[0]} \\d+ + Set To Dictionary ${SONOBUOY_IMGS['e2e']} name=conformance:${gitVersion[0]} Onboard Images ${INT_REG}= Get Variable Value ${INTERNAL_REGISTRY} ${EMPTY} diff --git a/tox.ini b/tox.ini index bfba457..09385ec 100644 --- a/tox.ini +++ b/tox.ini @@ -29,7 +29,6 @@ deps = requests~=2.21.0 nodeenv commands = - rm -rf docker/kube-conformance/kube-conformance docker/sonobuoy-plugin-systemd-logs/sonobuoy-plugin-systemd-logs nodeenv -p npm install --global write-good eslint complexity-report@2.0.0-alpha wget --timeout=120 -q https://github.com/pmd/pmd/releases/download/pmd_releases/6.15.0/pmd-bin-6.15.0.zip