{"id":21542418,"url":"https://github.com/kool-dev/healthz","last_synced_at":"2025-04-10T04:25:00.899Z","repository":{"id":55438893,"uuid":"315443670","full_name":"kool-dev/healthz","owner":"kool-dev","description":"Utility to simplify health check applications.","archived":false,"fork":false,"pushed_at":"2021-01-16T13:33:58.000Z","size":39,"stargazers_count":4,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-24T05:43:43.601Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kool-dev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-11-23T21:20:47.000Z","updated_at":"2021-12-10T21:12:46.000Z","dependencies_parsed_at":"2022-08-15T00:20:28.412Z","dependency_job_id":null,"html_url":"https://github.com/kool-dev/healthz","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kool-dev%2Fhealthz","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kool-dev%2Fhealthz/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kool-dev%2Fhealthz/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kool-dev%2Fhealthz/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kool-dev","download_url":"https://codeload.github.com/kool-dev/healthz/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248156092,"owners_count":21056768,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-24T05:09:32.328Z","updated_at":"2025-04-10T04:25:00.875Z","avatar_url":"https://github.com/kool-dev.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# healthz\n\n[![Kool.dev](https://kool.dev/img/logo.png)](https://kool.dev)\n\nUtility to simplify health check on container applications.\n\n---\n\n[![Go Report Card](https://goreportcard.com/badge/github.com/kool-dev/healthz)](https://goreportcard.com/report/github.com/kool-dev/healthz)\n[![codecov](https://codecov.io/gh/kool-dev/healthz/branch/main/graph/badge.svg?token=6JP8JRVF5U)](https://codecov.io/gh/kool-dev/healthz)\n[![Maintainability](https://api.codeclimate.com/v1/badges/8cbfe7f40b29386e532d/maintainability)](https://codeclimate.com/github/kool-dev/healthz/maintainability)\n[\u003cimg src=\"https://img.shields.io/badge/Join%20Slack-kool--dev-orange?logo=slack\"\u003e](https://join.slack.com/t/kool-dev/shared_invite/zt-jeh36s5g-kVFHUsyLjFENUUH4ucrxPg)\n\n### Installation\n\n`healthz` is available with a one-line install script for Linux:\n\n```bash\ncurl -fsSL https://raw.githubusercontent.com/kool-dev/healthz/main/install.sh | bash\n```\n\n### Usage\n\n`healthz` receives a JSON array as parameter, which contains all tests it needs to perform.\n\nAfter executing all the checks, it will exit with with `0` exit code for success, and non-zero otherwise.\n\n```bash\n# check for a TCP listening port to accept connections\nhealthz -i '[{\"type\": \"tcp\", \"value\": \"localhost:80\"}]'\n\n# check for an HTTP server to respond with a 200 status code\nhealthz -i '[{\"type\": \"http\", \"value\": \"http://localhost\"}]'\n\n# execute a command and check for exit code to be zero\nhealthz -i '[{\"type\": \"exec\", \"value\": \"ls -lah /\"}]'\n```\n\n### Docker image\n\nWe also provide a single binary Docker image with `healthz`. The image can be used to fetch the binary easily on other images you want to add health check to.\n\nAdding it to your own images:\n\n```Dockerfile\nCOPY --from=kooldev/healthz /healthz /healthz\n```\n\nRunning it with Docker:\n\n```console\n$ docker run --rm kooldev/healthz:1.0 -i \"...\"\n```\n\n## License\n\nThe MIT License (MIT). Please see [License File](LICENSE.md) for more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkool-dev%2Fhealthz","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkool-dev%2Fhealthz","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkool-dev%2Fhealthz/lists"}