mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 19:56:01 +00:00
Added more logs to Autoscaling e2e test
This commit is contained in:
parent
9d1a48d5f6
commit
72c27d5782
@ -94,7 +94,7 @@ var _ = Describe("Autoscaling", func() {
|
|||||||
func setUpAutoscaler(metric string, target float64, min, max int) {
|
func setUpAutoscaler(metric string, target float64, min, max int) {
|
||||||
// TODO integrate with kube-up.sh script once it will support autoscaler setup.
|
// TODO integrate with kube-up.sh script once it will support autoscaler setup.
|
||||||
By("Setting up autoscaler to scale based on " + metric)
|
By("Setting up autoscaler to scale based on " + metric)
|
||||||
_, err := exec.Command("gcloud", "preview", "autoscaler",
|
out, err := exec.Command("gcloud", "preview", "autoscaler",
|
||||||
"--zone="+testContext.CloudConfig.Zone,
|
"--zone="+testContext.CloudConfig.Zone,
|
||||||
"create", "e2e-test-autoscaler",
|
"create", "e2e-test-autoscaler",
|
||||||
"--project="+testContext.CloudConfig.ProjectID,
|
"--project="+testContext.CloudConfig.ProjectID,
|
||||||
@ -105,13 +105,13 @@ func setUpAutoscaler(metric string, target float64, min, max int) {
|
|||||||
fmt.Sprintf("--min-num-replicas=%v", min),
|
fmt.Sprintf("--min-num-replicas=%v", min),
|
||||||
fmt.Sprintf("--max-num-replicas=%v", max),
|
fmt.Sprintf("--max-num-replicas=%v", max),
|
||||||
).CombinedOutput()
|
).CombinedOutput()
|
||||||
expectNoError(err)
|
expectNoError(err, "Output: "+string(out))
|
||||||
}
|
}
|
||||||
|
|
||||||
func cleanUpAutoscaler() {
|
func cleanUpAutoscaler() {
|
||||||
By("Removing autoscaler")
|
By("Removing autoscaler")
|
||||||
_, err := exec.Command("gcloud", "preview", "autoscaler", "--zone="+testContext.CloudConfig.Zone, "delete", "e2e-test-autoscaler").CombinedOutput()
|
out, err := exec.Command("gcloud", "preview", "autoscaler", "--zone="+testContext.CloudConfig.Zone, "delete", "e2e-test-autoscaler").CombinedOutput()
|
||||||
expectNoError(err)
|
expectNoError(err, "Output: "+string(out))
|
||||||
}
|
}
|
||||||
|
|
||||||
func CreateService(f *Framework, name string) {
|
func CreateService(f *Framework, name string) {
|
||||||
|
Loading…
Reference in New Issue
Block a user