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
When I send TERM to prometheus-ecs-discovery, it exits with the status 2. An exit status between 1 and 127 usually indicates an error, so we report this.
When a program ends because of a signal, it should exit with the exit code 128 + Signal number, see https://wiki.jenkins.io/display/JENKINS/Job+Exit+Status. When Docker wants to stop a container, it sends the TERM signal (TERM = 15) to the process in the container, so that process should terminate with code 143.
It would be great if prometheus-ecs-discovery would exit with 143 when receiving TERM instead of 2, so we don't get reports of failed processes just because we deployed it for example.
The text was updated successfully, but these errors were encountered:
I'm having the same issue when trying to call prometheus-ecs-discover -help and it's returning exit code 2. According to this thread golang/go#37533 I think by adding a help flag it will return a status code 0. The only reason it's returning a status code 2 is b/c the help flag isn't explicitly defined.
My use case is that i'm trying to verify in my docker image that I can call the prometheus-ecs-discovery executable as a sanity check but it's failing my circleci build due to returning exit code 2.
When I send
TERM
toprometheus-ecs-discovery
, it exits with the status 2. An exit status between 1 and 127 usually indicates an error, so we report this.When a program ends because of a signal, it should exit with the exit code 128 + Signal number, see https://wiki.jenkins.io/display/JENKINS/Job+Exit+Status. When Docker wants to stop a container, it sends the
TERM
signal (TERM
= 15) to the process in the container, so that process should terminate with code 143.It would be great if
prometheus-ecs-discovery
would exit with 143 when receiving TERM instead of 2, so we don't get reports of failed processes just because we deployed it for example.The text was updated successfully, but these errors were encountered: