Class ContainerMonitorService
java.lang.Object
com.ammann.servicemanager.service.ContainerMonitorService
Scheduled background service that monitors Docker containers.
Performs two periodic tasks:
- Checks for available image updates for remote containers (every 5 minutes).
- Verifies that all containers are in the "running" state (every 30 seconds).
Local images (those without a registry prefix) are excluded from update checks because they cannot be pulled from a remote registry.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidIterates over all running containers and checks whether a newer image version is available in the remote registry.voidLogs a warning for each container that is not in the "running" state.
-
Constructor Details
-
ContainerMonitorService
public ContainerMonitorService()
-
-
Method Details
-
checkForUpdates
public void checkForUpdates()Iterates over all running containers and checks whether a newer image version is available in the remote registry. Local images are skipped. -
healthCheck
public void healthCheck()Logs a warning for each container that is not in the "running" state.
-