From dd89c5119c7e24e9b54184e1b2a4e2378f232e02 Mon Sep 17 00:00:00 2001 From: Erik Wilson Date: Tue, 12 Nov 2019 16:35:54 -0700 Subject: [PATCH 1/3] Bump go to 1.13.4 --- Dockerfile.dapper | 2 +- Dockerfile.sonobuoy.dapper | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile.dapper b/Dockerfile.dapper index 02987e0b66..4c0b9e2ddc 100644 --- a/Dockerfile.dapper +++ b/Dockerfile.dapper @@ -1,4 +1,4 @@ -FROM golang:1.12.12-alpine3.10 +FROM golang:1.13.4-alpine3.10 RUN apk -U --no-cache add bash git gcc musl-dev docker vim less file curl wget ca-certificates jq linux-headers zlib-dev tar zip squashfs-tools npm coreutils \ python3 py3-pip python3-dev openssl-dev libffi-dev libseccomp libseccomp-dev make libuv-static diff --git a/Dockerfile.sonobuoy.dapper b/Dockerfile.sonobuoy.dapper index 0563598e31..c9c56e1992 100644 --- a/Dockerfile.sonobuoy.dapper +++ b/Dockerfile.sonobuoy.dapper @@ -1,4 +1,4 @@ -FROM golang:1.13.3-alpine3.10 +FROM golang:1.13.4-alpine3.10 RUN apk -U --no-cache add bash git gcc musl-dev docker curl jq coreutils python2 RUN SONOBUOY_VER=v0.16.2 && \ From 671d702dc1f21b2970bfe078f386f8c71d2ab5b7 Mon Sep 17 00:00:00 2001 From: Erik Wilson Date: Tue, 12 Nov 2019 16:36:04 -0700 Subject: [PATCH 2/3] Build cleanup --- scripts/build | 12 ++++++------ scripts/download | 4 ++-- scripts/package-airgap | 4 ++-- scripts/package-cli | 4 ++-- scripts/package-image | 4 ++-- scripts/sonobuoy-e2e-tests | 2 +- scripts/version.sh | 4 ++-- 7 files changed, 17 insertions(+), 17 deletions(-) diff --git a/scripts/build b/scripts/build index d48a6068b7..96ac81028f 100755 --- a/scripts/build +++ b/scripts/build @@ -1,18 +1,18 @@ #!/bin/bash set -e -x -source $(dirname $0)/version.sh - cd $(dirname $0)/.. + +. ./scripts/version.sh + PKG="github.com/rancher/k3s" PKG_CONTAINERD="github.com/containerd/containerd" PKG_RANCHER_CONTAINERD="github.com/rancher/containerd" PKG_CRICTL="github.com/kubernetes-sigs/cri-tools" -VENDOR_PREFIX= -if [ -z "$(go mod why 2>/dev/null)" ]; then - VENDOR_PREFIX="${PKG}/vendor/" -fi +export GO111MODULE=off + +VENDOR_PREFIX="${PKG}/vendor/" VERSIONFLAGS=" -X ${PKG}/pkg/version.Version=${VERSION} -X ${PKG}/pkg/version.GitCommit=${COMMIT:0:8} diff --git a/scripts/download b/scripts/download index 11070788ed..d1d79607c6 100755 --- a/scripts/download +++ b/scripts/download @@ -1,9 +1,9 @@ #!/bin/bash -source $(dirname $0)/version.sh - cd $(dirname $0)/.. +. ./scripts/version.sh + ROOT_VERSION=v0.3.0 TRAEFIK_VERSION=1.77.1 CHARTS_DIR=build/static/charts diff --git a/scripts/package-airgap b/scripts/package-airgap index adc242fa2e..36dbeb0be1 100755 --- a/scripts/package-airgap +++ b/scripts/package-airgap @@ -1,10 +1,10 @@ #!/bin/bash set -e -x -source $(dirname $0)/version.sh - cd $(dirname $0)/.. +. ./scripts/version.sh + images=$(cat scripts/airgap/image-list.txt) xargs -n1 docker pull <<< "${images}" docker save ${images} -o dist/artifacts/k3s-airgap-images-${ARCH}.tar diff --git a/scripts/package-cli b/scripts/package-cli index ec31409d12..8d473e82e4 100755 --- a/scripts/package-cli +++ b/scripts/package-cli @@ -1,10 +1,10 @@ #!/bin/bash set -e -x -source $(dirname $0)/version.sh - cd $(dirname $0)/.. +. ./scripts/version.sh + rm -rf bin/crictl bin/kubectl bin/k3s-agent bin/k3s-server bin/kubectl bin/k3s build/data ln -s containerd bin/k3s-agent ln -s containerd bin/k3s-server diff --git a/scripts/package-image b/scripts/package-image index 83e803c44a..69f3369ffe 100755 --- a/scripts/package-image +++ b/scripts/package-image @@ -1,10 +1,10 @@ #!/bin/bash set -e -source $(dirname $0)/version.sh - cd $(dirname $0)/.. +. ./scripts/version.sh + TAG=${TAG:-${VERSION}${SUFFIX}} REPO=${REPO:-rancher} IMAGE_NAME=${IMAGE_NAME:-k3s} diff --git a/scripts/sonobuoy-e2e-tests b/scripts/sonobuoy-e2e-tests index d6a4fafc5f..78eece8820 100755 --- a/scripts/sonobuoy-e2e-tests +++ b/scripts/sonobuoy-e2e-tests @@ -4,7 +4,7 @@ set -e -x cd $(dirname $0)/.. if [ -z "$K3S_IMAGE" ]; then - source $(dirname $0)/version.sh + . ./scripts/version.sh TAG=${TAG:-${VERSION}${SUFFIX}} REPO=${REPO:-rancher} IMAGE_NAME=${IMAGE_NAME:-k3s} diff --git a/scripts/version.sh b/scripts/version.sh index f412dc9b1a..6eb101c777 100755 --- a/scripts/version.sh +++ b/scripts/version.sh @@ -16,8 +16,8 @@ fi ARCH=$(go env GOARCH) SUFFIX="-${ARCH}" -VERSION_CONTAINERD=$(grep github.com/containerd/containerd $(dirname $0)/../go.mod | head -n1 | awk '{print $4}') -VERSION_CRICTL=$(grep github.com/kubernetes-sigs/cri-tools $(dirname $0)/../go.mod | head -n1 | awk '{print $4}') +VERSION_CONTAINERD=$(grep github.com/containerd/containerd go.mod | head -n1 | awk '{print $4}') +VERSION_CRICTL=$(grep github.com/kubernetes-sigs/cri-tools go.mod | head -n1 | awk '{print $4}') if [ -z "$VERSION_CONTAINERD" ]; then VERSION_CONTAINERD="v0.0.0" From 0a843a11c6c705f1c6eb0b33c49338337ececea9 Mon Sep 17 00:00:00 2001 From: Erik Wilson Date: Tue, 12 Nov 2019 18:20:57 -0700 Subject: [PATCH 3/3] Show single sonobuoy failure --- scripts/test-helpers | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/test-helpers b/scripts/test-helpers index cf931487fb..d425f31987 100755 --- a/scripts/test-helpers +++ b/scripts/test-helpers @@ -128,7 +128,7 @@ retrieve-sonobuoy-logs() { if [ -n "${E2E_LOG_OUTPUT}" ]; then cp ${RESULTS} $(sed -e "s/-STATUS-/-${status}-/g" <<< "${E2E_LOG_OUTPUT}") fi - awk '/^Summarizing .* Failures:$/,0' ${RESULTS} + awk '/^Summarizing .* Failures?:$/,0' ${RESULTS} return ${exit_code} } export -f retrieve-sonobuoy-logs