Post

Container healthcheck loop

A year ago I was figuring out the topic and simultaneously practicing with puml. Sometimes it is very useful in a graphic form, it seems clear to me.

  • Script

    1
    2
    3
    
      FROM ubuntu 
      HEALTHCHECK --interval=12s --timeout=3s \ 
      CMD curl -f http://localhost/ || exit 1 
    
  • Args

    • --interval=DURATION (default: 30s)
    • --timeout=DURATION (default: 30s)
    • --retries=N (default: 3)
    • --start-period=DURATION (default: 0s)
    • --start-interval=DURATION (default: 5s)
  • Loop

Healthcheck loop

This post is licensed under CC BY 4.0 by the author.