I have noticed that there are 3 very old templates that tend to circle around the concept of zombie processes, but recently I have made my own. This is step 1 of 2 on what I intended to release. This is step 1: monitoring FOR the number of zombie processes, so that you can alert accordingly.
Step 2 in this process will be a separate script that will instead kill all the parent processes that caused the zombies, and return a count after of the number of zombie processes that could not be remediated. Be aware of what this means from an automation standpoint, lest you break something and get to play linux sysadmin in some new ways. Should you choose the latter version when I release it without a good understanding how this works and what the implications are, I would recommend deployment while listening to something akin to Dio's Holy Diver, and wish you luck in your newfound linux syadmin role.