Looking to hire Laravel developers? Try LaraJobs

laravel-healthcheck maintained by patrickfischer

Last update
2026/10/08 06:40 (dev-main)
License
Links
Downloads
23

Comments
comments powered by Disqus

Laravel Docker Ping Health Check

A simple Laravel package that simplifies Docker health check.

Installation

Install it with composer:

composer require patrickfischer/laravel-healthcheck

Update your Docker health check script to curl the newly registered route /ping, or whatever you declare in config('laravel-healthcheck.route') The following is an example health check script, please update your own implementation:

#!/usr/bin/env bash
set -e

if [ $(curl -o /dev/null -L -s -w "%{http_code}\n" http://localhost/ping) = "200" ]; then
    exit 0
else
    exit 1
fi    

License

MIT