docker run, add restart option "limited" #47801
Labels
kind/feature
Functionality or other elements that the project doesn't currently have. Features are new and shiny
status/0-triage
Description
The documentation as today (2024-05-06) is
the
restart=on-failure:3
almost covers the request. Theon-failure:3
restarts 3 times the container if the container exits with a "bad" status code. Instead sometimes one wants to give a limited number of restarts (and then one needs to investigate) to containers that may exit with a good status code (likeexit 0
).Yes I know, the application should be good enough to exit with a proper status code in case of error, but in the real world not all applications exit with proper status codes. Therefore a
restart=limited:3
could help in this case.Hopefully it could be implemented without a major effort. Thank you!
The text was updated successfully, but these errors were encountered: