Bash.exe processes not killed on windows runner

Summary

  • Windows Runner
  • Executor is set to Shell
  • Shell = bash.exe

Processes scripted in this bash.exe are not killed when a job is terminated

Steps to reproduce

  • With the above configuration, set a ci job to create sub-processes of the bash.exe
  • Stop/terminate the job (rails UI)
  • Job is halted, but bash.exe processes on runner continue to execute
.gitlab-ci.yml
Add the job definition that is failing here

Actual behavior

Processes continue running after the job is stopped

Expected behavior

Processes are killed/terminated when the runner job is stopped

Relevant logs and/or screenshots

Windows_runner_error

job log
Add the job log

Environment description

config.toml contents
concurrent = 1 #changed to 1 to handle UE build tool being used
check_interval = 30
shutdown_timeout = 0

[session_server]
  session_timeout = 1800

[[runners]]
  name = "win10_scout"
  url = "https://redacted.com"
  id = 0
  token = 
  token_obtained_at = 0001-01-01T00:00:00Z
  token_expires_at = 0001-01-01T00:00:00Z
  executor = "shell"
  shell = "powershell"
  [runners.cache]
    MaxUploadedArchiveSize = 0

[[runners]]
  name = "win10_scout_camp"
  url = "https://redacted.com"
  id = 746
  token = 
  token_obtained_at = 2023-09-08T18:44:07Z
  token_expires_at = 0001-01-01T00:00:00Z
  executor = "shell"
  shell = "powershell"
  [runners.cache]
    MaxUploadedArchiveSize = 0

Used GitLab Runner version

Possible fixes

Possible workaround, if coreutils is available on Windows, use timeout

Edited by Nathan Black