Posts

Showing posts with the label healthcheck

HEALTHCHECK Instructions in Dockerfile

Image
 Hello Guys in this post I wish to explore more intresting instructions HEALTHCHECK which can be used in Dockerfile.  The most common requirement for any real-time projects monitoring using a side-car container which could run in parallel and try to check the process or application URL check or container reachability using ping command etc.  Dockerfie instruction HEALTHCHECK In Dockerfile we can have HEALTHCHECK instruction that allows us to know the condition of an application test runs as expected or not, when a container runs this will be returns a status as healthy, unhealthy based on the HEALTHCHECK command exit code. If the exit code 0 then returns healthy otherwise unhealthy. HEALTHCHECK [options] CMD [health check command] Example: HEALTHCHECK --interval=3s CMD ping c1 172.17.0.2 here are the Healthcheck options   --interval=time in sec (duration 30s is default)  --timeout=time in sec (duration 30s is default)  --start-period=time in ...

Ansible 11 The uri module with examples

Image
 Hey DevSecOps Automation specialist, Welcome back to the DevOps Hunter blog. In this post, I made it for learning more about all possible parameters that we can use when an application validation is done with the Ansible 'uri' module.  Why uri module? Web Application returns status HTTPCode 200 for success, 404 for failures, and also for 503 for Server internal issues. When you work on the restart of a web application we need to know the status of the application to proceed with the next move. So this uri module is most important for reboot and restart of web applications using ansible. The uri module parameters Supported parameters include: attributes, backup, body, body_format, client_cert, client_key, content, creates, delimiter, dest, directory_mode, follow, follow_redirects, force, force_basic_auth, group, headers, http_agent, method, mode, owner, regexp, remote_src, removes, return_content, selevel, serole, setype, seuser, src, status_code, timeout,...