renatomefi / php-fpm-healthcheck

A POSIX compliant sh script to healthcheck PHP fpm status, can be used only for pinging or check for specific metrics
MIT License
491 stars 55 forks source link

Fix command for use on debian #24

Closed roynasser closed 5 years ago

roynasser commented 5 years ago

On debian based images this was failing. I traced it to env -i requiring the full path to the command.

In this PR, I have added $(which cgi-fcgi) to return the full path.

I came across this when php-fpm-healthcheck stopped working intermitently in our kube cluster. Turns out the ENV was growing and beginning to fail.

roynasser commented 5 years ago

@renatomefi I'm not hehe...

I download it manually and add it to our docker build pack... its going into a "base php" image we use, so its in only 1 place at a time but still its manual. Since its something that "just works" on the current version, I was a bit skeptical to download it everytime from github, for example...

Any other suggestions on how to do it?

renatomefi commented 5 years ago

@roynasser

Not sure exactly, I was thinking about exposing a file with the current version number, then one could use a script to detect whether they have an outdated version and get warned about it, but seems like it's not an issue so far, I'm just curious to know how the users are doing it!