monitoring-unhealthy-containers.rst
28 lines
| 901 B
| text/x-rst
|
RstLexer
r306 | .. _monitoring-unhealthy-containers: | ||
========================================= | |||
Monitor for stale or unhealthy containers | |||
========================================= | |||
In case for bigger setups or high volume environments it can happen that workers or whole docker | |||
containers become unresponsive or unhealthy | |||
rcstack has a special command to restart those containers that become unhealthy to guarantee that | |||
there are always workable containers to handle the traffic. | |||
.. code-block:: bash | |||
./rcstack stack-monitor restart-unhealthy | |||
This will seek any containers that have a broken healthcheck status, and restart them gracefully. | |||
It's also possible to run this command continuously in the background using | |||
.. code-block:: bash | |||
nohup ./rcstack restart-unhealthy --loop=300 > unhealthy-checks.log & | |||
This will continuously run in a loop check every 300s and check for unhealthy containers. |