mirror of https://github.com/k3s-io/k3s
Merge pull request #20865 from maisem/master
Adding a readiness probe to kubectl e2e tests.pull/6/head
commit
1c6a223eaa
|
@ -99,8 +99,7 @@ readonly KUBE_TEST_TARGETS=($(kube::golang::test_targets))
|
|||
readonly KUBE_TEST_BINARIES=("${KUBE_TEST_TARGETS[@]##*/}")
|
||||
readonly KUBE_TEST_BINARIES_WIN=("${KUBE_TEST_BINARIES[@]/%/.exe}")
|
||||
readonly KUBE_TEST_PORTABLE=(
|
||||
test/images/network-tester/rc.json
|
||||
test/images/network-tester/service.json
|
||||
test/e2e/testing-manifests
|
||||
test/kubemark
|
||||
hack/e2e.go
|
||||
hack/e2e-internal
|
||||
|
|
|
@ -170,8 +170,8 @@ var _ = Describe("Kubectl client", func() {
|
|||
var podPath string
|
||||
|
||||
BeforeEach(func() {
|
||||
podPath = filepath.Join(testContext.RepoRoot, "docs/user-guide/pod.yaml")
|
||||
By("creating the pod")
|
||||
podPath = filepath.Join(testContext.RepoRoot, "test", "e2e", "testing-manifests", "kubectl", "pod-with-readiness-probe.yaml")
|
||||
By(fmt.Sprintf("creating the pod from %v", podPath))
|
||||
runKubectlOrDie("create", "-f", podPath, fmt.Sprintf("--namespace=%v", ns))
|
||||
checkPodsRunningReady(c, ns, []string{simplePodName}, podStartTimeout)
|
||||
})
|
||||
|
|
|
@ -38,7 +38,7 @@ func getLoadBalancerControllers(repoRoot string, client *client.Client) []LBCTes
|
|||
return []LBCTester{
|
||||
&haproxyControllerTester{
|
||||
name: "haproxy",
|
||||
cfg: filepath.Join(repoRoot, "test", "e2e", "testing-manifests", "haproxyrc.yaml"),
|
||||
cfg: filepath.Join(repoRoot, "test", "e2e", "testing-manifests", "serviceloadbalancer", "haproxyrc.yaml"),
|
||||
client: client,
|
||||
},
|
||||
}
|
||||
|
@ -49,8 +49,8 @@ func getIngManagers(repoRoot string, client *client.Client) []*ingManager {
|
|||
return []*ingManager{
|
||||
{
|
||||
name: "netexec",
|
||||
rcCfgPaths: []string{filepath.Join(repoRoot, "test", "e2e", "testing-manifests", "netexecrc.yaml")},
|
||||
svcCfgPaths: []string{filepath.Join(repoRoot, "test", "e2e", "testing-manifests", "netexecsvc.yaml")},
|
||||
rcCfgPaths: []string{filepath.Join(repoRoot, "test", "e2e", "testing-manifests", "serviceloadbalancer", "netexecrc.yaml")},
|
||||
svcCfgPaths: []string{filepath.Join(repoRoot, "test", "e2e", "testing-manifests", "serviceloadbalancer", "netexecsvc.yaml")},
|
||||
svcNames: []string{},
|
||||
client: client,
|
||||
},
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
apiVersion: v1
|
||||
kind: Pod
|
||||
metadata:
|
||||
name: nginx
|
||||
labels:
|
||||
name: nginx
|
||||
spec:
|
||||
containers:
|
||||
- name: nginx
|
||||
image: nginx
|
||||
ports:
|
||||
- containerPort: 80
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 80
|
||||
initialDelaySeconds: 5
|
||||
timeoutSeconds: 5
|
Loading…
Reference in New Issue