pingcap / tidb-operator

TiDB operator creates and manages TiDB clusters running in Kubernetes.
https://docs.pingcap.com/tidb-in-kubernetes/
Apache License 2.0
1.22k stars 493 forks source link

Failed to run e2e test in private environment #1433

Closed shonge closed 4 years ago

shonge commented 4 years ago

Question

When I was following CONTRIBUTING.md run e2e test on my laptop, got this err:

[root@localhost tidb-operator]# make e2e
./hack/e2e.sh
DOCKER_REGISTRY: localhost:5000
IMAGE_TAG: latest
CLUSTER: tidb-operator
KUBECONFIG: /root/.kube/kind-config-kind
KUBECONTEXT: kind-tidb-operator
SKIP_BUILD:
SKIP_IMAGE_BUILD:
SKIP_UP:
SKIP_DOWN:
KIND_DATA_HOSTPATH: none
KUBE_VERSION: v1.12.10
DOCKER_IO_MIRROR:
info: starting a new cluster
./hack/e2e.sh: line 192: GCR_IO_MIRROR: unbound variable
info: cluster 'tidb-operator' does not exist, skip shutting down the cluster
make: *** [e2e] Error 1

Before asking a question, make sure you have:

cofyc commented 4 years ago

sorry, newly-added GCR_IO_MIRROR should be optional, I'll fix it soon.

btw, ./hack/kind-cluster-build.sh is not needed anymore, hack/e2e.sh will start a cluster internally.

./hack/e2e.sh -h will show some help information.

shonge commented 4 years ago

Use this command copy from Jenkins ci script can workaround the problem:

DOCKER_IO_MIRROR=https://dockerhub.azk8s.cn GCR_IO_MIRROR=https://gcr.azk8s.cn QUAY_IO_MIRROR=https://quay.azk8s.cn IMAGE_TAG=latest GINKGO_NODES=8 KUBE_VERSION=v1.17.0 REPORT_DIR=/root/e2e/ REPORT_PREFIX=v1.17.0_ ./hack/e2e.sh -- --ginkgo.skip=\[Serial\]