You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 5, 2021. It is now read-only.
When jaas terminates, for any reason (timeouts or the user cancels the task with CTRL-C for example), the service created should be removed so that, no "garbage" is left behing
If the flag --remove asks otherwise, don't remove the service
Current Behavior
When running a task, if the task timeouts or the user cancels the task with CTRL-C for example, the service will remaining and won't be removed
Possible Solution
From what I could understand in the code, the ServiceRemove function is only called when everything went "fine" (or at least, the service "finished" somehow):
The solution could be that the ServiceRemove function is called when the jaas process "stops" (CTRL-C must be captured) or the task timeouts.
Steps to Reproduce (for bugs)
docker -H "ssh://<manager>" run --rm -it -v /var/run/docker.sock:/var/run/docker.sock alexellis2/jaas run -r --image alexellis2/cows --timeout 1s
docker service ls will give sth like:
ID NAME MODE REPLICAS IMAGE PORTS
z9y5v33nohdo dreamy_sammet replicated 0/1 alexellis2/cows:latest
And docker service ps dreamy_sammet
ID NAME IMAGE NODE DESIRED STATE CURRENT STATE ERROR PORTS
prcz9a29sd9z dreamy_sammet.1 alexellis2/cows:latest db-001 Shutdown Complete 14 seconds ago
You see the desired state so the service is still there :)
Context
Either a task can timeout for several reason or the user might cancel the request because of a mistake or even, there is a problem with the docker daemon that cause the service/task to be stuck in "Preparing" state.
All these reasons leaves "service zoombie" behinds
Your Environment
Version used: (latest from hub.docker.com)
Environment name and version (e.g. Docker 1.13): Docker version 19.03.12, build 48a66213fe
Server type and version: VM Linux 4.19.0-10-cloud-amd64 Implement service removal flag #1 SMP Debian 4.19.132-1 (2020-07-24) x86_64 GNU/Linux
Operating System and version: Linux 4.19.0-10-cloud-amd64 Implement service removal flag #1 SMP Debian 4.19.132-1 (2020-07-24) x86_64 GNU/Linux
Link to your project: N/A
The text was updated successfully, but these errors were encountered:
Expected Behavior
When jaas terminates, for any reason (timeouts or the user cancels the task with CTRL-C for example), the service created should be removed so that, no "garbage" is left behing
If the flag --remove asks otherwise, don't remove the service
Current Behavior
When running a task, if the task timeouts or the user cancels the task with CTRL-C for example, the service will remaining and won't be removed
Possible Solution
From what I could understand in the code, the
ServiceRemove
function is only called when everything went "fine" (or at least, the service "finished" somehow):The solution could be that the
ServiceRemove
function is called when the jaas process "stops" (CTRL-C must be captured) or the task timeouts.Steps to Reproduce (for bugs)
docker -H "ssh://<manager>" run --rm -it -v /var/run/docker.sock:/var/run/docker.sock alexellis2/jaas run -r --image alexellis2/cows --timeout 1s
docker service ls
will give sth like:docker service ps dreamy_sammet
Context
Either a task can timeout for several reason or the user might cancel the request because of a mistake or even, there is a problem with the docker daemon that cause the service/task to be stuck in "Preparing" state.
All these reasons leaves "service zoombie" behinds
Your Environment
The text was updated successfully, but these errors were encountered: