File tree 2 files changed +11
-1
lines changed
scaletest/templates/scaletest-runner
2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -75,6 +75,15 @@ data "coder_parameter" "dry_run" {
75
75
ephemeral = true
76
76
}
77
77
78
+ data "coder_parameter" "repo_branch" {
79
+ order = 3
80
+ type = " string"
81
+ name = " Branch"
82
+ default = " main"
83
+ description = " Branch of coder/coder repo to check out (only useful for developing the runner)."
84
+ mutable = true
85
+ }
86
+
78
87
data "coder_parameter" "create_concurrency" {
79
88
order = 10
80
89
type = " number"
@@ -357,6 +366,7 @@ resource "coder_agent" "main" {
357
366
SCALETEST_RUN_DIR : local.scaletest_run_dir,
358
367
359
368
SCALETEST_PARAM_TEMPLATE : data.coder_parameter.workspace_template.value,
369
+ SCALETEST_PARAM_REPO_BRANCH : data.coder_parameter.repo_branch.value,
360
370
SCALETEST_PARAM_NUM_WORKSPACES : data.coder_parameter.num_workspaces.value,
361
371
SCALETEST_PARAM_CREATE_CONCURRENCY : " ${ data . coder_parameter . create_concurrency . value } " ,
362
372
SCALETEST_PARAM_CLEANUP_STRATEGY : data.coder_parameter.cleanup_strategy.value,
Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ echo "Cloning coder/coder repo..."
16
16
if [[ ! -d " ${HOME} /coder" ]]; then
17
17
git clone https://github.com/coder/coder.git " ${HOME} /coder"
18
18
fi
19
- (cd " ${HOME} /coder" && git pull)
19
+ (cd " ${HOME} /coder" && git fetch -a && git checkout " ${SCALETEST_PARAM_REPO_BRANCH} " && git pull)
20
20
21
21
# shellcheck disable=SC2153 source=scaletest/templates/scaletest-runner/scripts/lib.sh
22
22
. " ${SCRIPTS_DIR} /lib.sh"
You can’t perform that action at this time.
0 commit comments