types.healthcheck

Module Contents

Classes

Healthcheck(self,**kwargs) Defines a healthcheck configuration for a container or service.
class Healthcheck(**kwargs)

Defines a healthcheck configuration for a container or service.

Args:
test (list or str): Test to perform to determine

container health. Possible values:

  • Empty list: Inherit healthcheck from parent image
  • ["NONE"]: Disable healthcheck
  • ["CMD", args...]: exec arguments directly.
  • ["CMD-SHELL", command]: RUn command in the system’s default shell.

If a string is provided, it will be used as a CMD-SHELL command.

interval (int): The time to wait between checks in nanoseconds. It
should be 0 or at least 1000000 (1 ms).
timeout (int): The time to wait before considering the check to
have hung. It should be 0 or at least 1000000 (1 ms).
retries (integer): The number of consecutive failures needed to
consider a container as unhealthy.
start_period (integer): Start period for the container to
initialize before starting health-retries countdown in nanoseconds. It should be 0 or at least 1000000 (1 ms).
__init__(**kwargs)
test()
test(value)
interval()
interval(value)
timeout()
timeout(value)
retries()
retries(value)
start_period()
start_period(value)