File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -445,6 +445,8 @@ func (r *GatlingReconciler) newGatlingRunnerJobForCR(gatling *gatlingv1alpha1.Ga
445
445
r .getGenerateLocalReport (gatling ))
446
446
log .Info ("gatlingRunnerCommand:" , "comand" , gatlingRunnerCommand )
447
447
448
+ var noRestarts int32 = 0
449
+
448
450
envVars := gatling .Spec .TestScenarioSpec .Env
449
451
if gatling .Spec .GenerateReport {
450
452
gatlingTransferResultCommand := commands .GetGatlingTransferResultCommand (
@@ -461,6 +463,7 @@ func (r *GatlingReconciler) newGatlingRunnerJobForCR(gatling *gatlingv1alpha1.Ga
461
463
Labels : labels ,
462
464
},
463
465
Spec : batchv1.JobSpec {
466
+ BackoffLimit : & noRestarts ,
464
467
Parallelism : r .getGatlingRunnerJobParallelism (gatling ),
465
468
Completions : r .getGatlingRunnerJobParallelism (gatling ),
466
469
Template : corev1.PodTemplateSpec {
@@ -527,6 +530,7 @@ func (r *GatlingReconciler) newGatlingRunnerJobForCR(gatling *gatlingv1alpha1.Ga
527
530
Labels : labels ,
528
531
},
529
532
Spec : batchv1.JobSpec {
533
+ BackoffLimit : & noRestarts ,
530
534
Parallelism : & gatling .Spec .TestScenarioSpec .Parallelism ,
531
535
Completions : & gatling .Spec .TestScenarioSpec .Parallelism ,
532
536
Template : corev1.PodTemplateSpec {
Original file line number Diff line number Diff line change @@ -68,11 +68,13 @@ if [ ! -d ${RESULTS_DIR_PATH} ]; then
68
68
fi
69
69
gatling.sh -sf ${SIMULATIONS_DIR_PATH} -s %s -rsf ${RESOURCES_DIR_PATH} -rf ${RESULTS_DIR_PATH} %s
70
70
71
- if [ $? -ne 0 ]; then
71
+ GATLING_EXIT_STATUS=$?
72
+ if [ $GATLING_EXIT_STATUS -ne 0 ]; then
72
73
RUN_STATUS_FILE="${RESULTS_DIR_PATH}/FAILED"
73
74
echo "gatling.sh has failed!" 1>&2
74
75
fi
75
76
touch ${RUN_STATUS_FILE}
77
+ exit $GATLING_EXIT_STATUS
76
78
`
77
79
generateLocalReportOption := "-nr"
78
80
if generateLocalReport {
You can’t perform that action at this time.
0 commit comments