Skip to content

Commit

Permalink
Add --health-on-failure
Browse files Browse the repository at this point in the history
Signed-off-by: Strahil Nikolov <[email protected]>
  • Loading branch information
hunter86bg committed May 31, 2024
1 parent d905a7c commit 980417d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions podman_compose.py
Original file line number Diff line number Diff line change
Expand Up @@ -1218,6 +1218,10 @@ async def container_to_args(compose, cnt, detached=True):
if "start_period" in healthcheck:
podman_args.extend(["--healthcheck-start-period", healthcheck["start_period"]])

# check if any action must be taken on healtcheck failure
if "on_failure" in healthcheck:
podman_args.extend(["--health-on-failure", healthcheck["on_failure"]])

# convert other parameters to string
if "retries" in healthcheck:
podman_args.extend(["--healthcheck-retries", str(healthcheck["retries"])])
Expand Down

0 comments on commit 980417d

Please sign in to comment.