Skip to content

Commit 4754f2f

Browse files
committed
fix updating of static time
1 parent f58bf41 commit 4754f2f

File tree

1 file changed

+4
-3
lines changed
  • scaletest/templates/scaletest-runner

1 file changed

+4
-3
lines changed

scaletest/templates/scaletest-runner/main.tf

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,11 @@ terraform {
1313

1414
resource "time_static" "start_time" {
1515
# We con't set `count = data.coder_workspace.me.start_count` here because then
16-
# we can't use this value in `locals`. The permission check is recreated on
17-
# start, which will update the timestamp.
16+
# we can't use this value in `locals`, but we want to trigger recreation when
17+
# the scaletest is restarted.
1818
triggers = {
19-
count : length(null_resource.permission_check)
19+
count : data.coder_workspace.me.start_count
20+
id : data.coder_workspace.me.start_count > 0 ? data.coder_workspace.me.id : ""
2021
}
2122
}
2223

0 commit comments

Comments
 (0)