Created
March 27, 2019 20:38
-
-
Save tstromberg/9e4ebdc17b66df7eb9480ee18d4b1fb0 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # This script executes the Kubernetes conformance tests in accordance with: | |
| # https://github.com/cncf/k8s-conformance/blob/master/instructions.md | |
| # | |
| # Usage: | |
| # conformance_tests.sh <path to minikube> <flags> | |
| # | |
| # Example: | |
| # conformance_tests.sh ./out/minikube --vm-driver=hyperkit | |
| set -ex -o pipefail | |
| readonly PROFILE_NAME="k8sconformance" | |
| readonly MINIKUBE=${1:-./out/minikube} | |
| shift || true | |
| readonly START_ARGS=$* | |
| # Requires a fully running Kubernetes cluster. | |
| "${MINIKUBE}" delete -p "${PROFILE_NAME}" || true | |
| "${MINIKUBE}" start -p "${PROFILE_NAME}" $START_ARGS | |
| "${MINIKUBE}" status -p "${PROFILE_NAME}" | |
| kubectl get pods --all-namespaces | |
| go get -u -v github.com/heptio/sonobuoy | |
| sonobuoy run --wait | |
| outdir="$(mktemp -d)" | |
| sonobuoy retrieve "${out_dir}" | |
| cd "${out_dir}" | |
| mkdir ./results; tar xzf *.tar.gz -C ./results | |
| mkdir minikube-${VERSION} | |
| cd minikube-${VERSION} | |
| version=$(${MINIKUBE} version | cut -d" " -f3) | |
| cat <<EOF >PRODUCT.yaml | |
| vendor: minikube | |
| name: minikube | |
| version: ${version} | |
| website_url: https://github.com/kubernetes/minikube | |
| repo_url: https://github.com/kubernetes/minikube | |
| documentation_url: https://github.com/kubernetes/minikube/blob/master/docs/README.md | |
| product_logo_url: https://raw.githubusercontent.com/kubernetes/minikube/master/images/logo/logo.svg | |
| type: installer | |
| description: minikube runs a local Kubernetes cluster on macOS, Linux, and Windows. | |
| EOF | |
| cat <<EOF >README.md | |
| ./hack/conformance_tests.sh minikube $2- | |
| EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment