setup_monitoring

Function setup_monitoring 

Source
pub fn setup_monitoring(
    config: &Config,
    rollback: &RollbackManager,
) -> Result<(), Box<dyn Error>>
Expand description

Sets up the monitoring system based on the provided configuration.

This function orchestrates the installation and configuration of Prometheus, Grafana, and Node Exporter. If monitoring is disabled in the configuration, it skips the setup.

§Arguments

  • config - A reference to the Config struct containing user-defined configuration options
  • rollback - A reference to the RollbackManager for managing system state

§Errors

Returns an error if any part of the monitoring setup process fails.