semaphoreui / semaphore

Modern UI and powerful API for Ansible, Terraform, OpenTofu, PowerShell and other DevOps tools.
https://semaphoreui.com
MIT License
10.61k stars 1.07k forks source link

Task stuck in "Running" state when Semaphore is restarted during run. #1385

Open linsomniac opened 1 year ago

linsomniac commented 1 year ago

I have a "apt dist-upgrade" job that I ran in Semaphore, which updated docker, which restarted Semaphore (I'm using the docker compose method to run it). I now have a task that is "Running", but there is no Ansible process associated with it.

Looks like if you have any task running and do a restart of Semaphore, it's going to be stuck on that task, presumably indefinitely. Mine has been running 12 hours. Clicking the "Stop" button in the task doesn't seem to do anything.

I'm thinking that at Semaphore startup time it needs to look for any "Running" tasks and clean up anything that is dangling.

Created a discussion here: https://github.com/ansible-semaphore/semaphore/discussions/1384

ansibleguy commented 1 year ago

Seems to be a duplicate of: https://github.com/ansible-semaphore/semaphore/issues/1376

linsomniac commented 1 year ago

Seems to be a duplicate of $1376, thanks @ansibleguy