From cd2e47b2fa7fdbbd24dd2e9333eb8488048816c9 Mon Sep 17 00:00:00 2001 From: eduartua Date: Mon, 28 Jan 2019 16:23:53 -0600 Subject: [PATCH] file cri-validation.md was moved to the new sig-node folder - URLs in k/community were updated --- contributors/devel/cri-validation.md | 54 +------------------ contributors/devel/sig-node/cri-validation.md | 53 ++++++++++++++++++ sig-node/charter.md | 2 +- 3 files changed, 56 insertions(+), 53 deletions(-) create mode 100644 contributors/devel/sig-node/cri-validation.md diff --git a/contributors/devel/cri-validation.md b/contributors/devel/cri-validation.md index 84842c9bf..d1ea4ad9f 100644 --- a/contributors/devel/cri-validation.md +++ b/contributors/devel/cri-validation.md @@ -1,53 +1,3 @@ -# Container Runtime Interface (CRI) Validation Testing +This file has moved to https://git.k8s.io/community/contributors/devel/sig-node/cri-validation.md. -CRI validation testing provides a test framework and a suite of tests to validate that the Container Runtime Interface (CRI) server implementation meets all the requirements. This allows the CRI runtime developers to verify that their runtime conforms to CRI, without needing to set up Kubernetes components or run Kubernetes end-to-end tests. - -CRI validation testing is GA since v1.11.0 and is hosted at the [cri-tools](https://github.com/kubernetes-sigs/cri-tools) repository. We encourage the CRI developers to report bugs or help extend the test coverage by adding more tests. - -## Install - -The test suites can be downloaded from cri-tools [release page](https://github.com/kubernetes-sigs/cri-tools/releases): - -```sh -VERSION="v1.11.0" -wget https://github.com/kubernetes-sigs/cri-tools/releases/download/$VERSION/critest-$VERSION-linux-amd64.tar.gz -sudo tar zxvf critest-$VERSION-linux-amd64.tar.gz -C /usr/local/bin -rm -f critest-$VERSION-linux-amd64.tar.gz -``` - -critest requires [ginkgo](https://github.com/onsi/ginkgo) to run parallel tests. It could be installed by - -```sh -go get -u github.com/onsi/ginkgo/ginkgo -``` - -*Note: ensure GO is installed and GOPATH is set before installing ginkgo.* - -## Running tests - -### Prerequisite - -Before running the test, you need to _ensure that the CRI server under test is running and listening on a Unix socket_. Because the validation tests are designed to request changes (e.g., create/delete) to the containers and verify that correct status is reported, it expects to be the only user of the CRI server. Please make sure that 1) there are no existing CRI-managed containers running on the node, and 2) no other processes (e.g., Kubelet) will interfere with the tests. - -### Run - -```sh -critest -``` - -This will - -- Connect to the shim of CRI container runtime -- Run the tests using `ginkgo` -- Output the test results to STDOUT - -critest connects to `unix:///var/run/dockershim.sock` by default. For other runtimes, the endpoint can be set by flags `-runtime-endpoint` and `-image-endpoint`. - -## Additional options - -- `-ginkgo.focus`: Only run the tests that match the regular expression. -- `-image-endpoint`: Set the endpoint of image service. Same with runtime-endpoint if not specified. -- `-runtime-endpoint`: Set the endpoint of runtime service. Default to `unix:///var/run/dockershim.sock`. -- `-ginkgo.skip`: Skip the tests that match the regular expression. -- `-parallel`: The number of parallel test nodes to run (default 1). ginkgo must be installed to run parallel tests. -- `-h`: Show help and all supported options. +This file is a placeholder to preserve links. Please remove by April 28, 2019 or the release of kubernetes 1.13, whichever comes first. \ No newline at end of file diff --git a/contributors/devel/sig-node/cri-validation.md b/contributors/devel/sig-node/cri-validation.md new file mode 100644 index 000000000..84842c9bf --- /dev/null +++ b/contributors/devel/sig-node/cri-validation.md @@ -0,0 +1,53 @@ +# Container Runtime Interface (CRI) Validation Testing + +CRI validation testing provides a test framework and a suite of tests to validate that the Container Runtime Interface (CRI) server implementation meets all the requirements. This allows the CRI runtime developers to verify that their runtime conforms to CRI, without needing to set up Kubernetes components or run Kubernetes end-to-end tests. + +CRI validation testing is GA since v1.11.0 and is hosted at the [cri-tools](https://github.com/kubernetes-sigs/cri-tools) repository. We encourage the CRI developers to report bugs or help extend the test coverage by adding more tests. + +## Install + +The test suites can be downloaded from cri-tools [release page](https://github.com/kubernetes-sigs/cri-tools/releases): + +```sh +VERSION="v1.11.0" +wget https://github.com/kubernetes-sigs/cri-tools/releases/download/$VERSION/critest-$VERSION-linux-amd64.tar.gz +sudo tar zxvf critest-$VERSION-linux-amd64.tar.gz -C /usr/local/bin +rm -f critest-$VERSION-linux-amd64.tar.gz +``` + +critest requires [ginkgo](https://github.com/onsi/ginkgo) to run parallel tests. It could be installed by + +```sh +go get -u github.com/onsi/ginkgo/ginkgo +``` + +*Note: ensure GO is installed and GOPATH is set before installing ginkgo.* + +## Running tests + +### Prerequisite + +Before running the test, you need to _ensure that the CRI server under test is running and listening on a Unix socket_. Because the validation tests are designed to request changes (e.g., create/delete) to the containers and verify that correct status is reported, it expects to be the only user of the CRI server. Please make sure that 1) there are no existing CRI-managed containers running on the node, and 2) no other processes (e.g., Kubelet) will interfere with the tests. + +### Run + +```sh +critest +``` + +This will + +- Connect to the shim of CRI container runtime +- Run the tests using `ginkgo` +- Output the test results to STDOUT + +critest connects to `unix:///var/run/dockershim.sock` by default. For other runtimes, the endpoint can be set by flags `-runtime-endpoint` and `-image-endpoint`. + +## Additional options + +- `-ginkgo.focus`: Only run the tests that match the regular expression. +- `-image-endpoint`: Set the endpoint of image service. Same with runtime-endpoint if not specified. +- `-runtime-endpoint`: Set the endpoint of runtime service. Default to `unix:///var/run/dockershim.sock`. +- `-ginkgo.skip`: Skip the tests that match the regular expression. +- `-parallel`: The number of parallel test nodes to run (default 1). ginkgo must be installed to run parallel tests. +- `-h`: Show help and all supported options. diff --git a/sig-node/charter.md b/sig-node/charter.md index dffbf7705..bad6360d7 100644 --- a/sig-node/charter.md +++ b/sig-node/charter.md @@ -66,7 +66,7 @@ None SIG Technical Leads -[validation]: https://github.com/kubernetes/community/blob/master/contributors/devel/cri-validation.md +[validation]: /contributors/devel/sig-node/cri-validation.md [testing policy]: /contributors/devel/sig-node/cri-testing-policy.md [test grid]: https://k8s-testgrid.appspot.com/sig-node#Summary [perf dashboard]: http://node-perf-dash.k8s.io/#/builds