pub fn setup_backup_system(
config: &Config,
rollback: &RollbackManager,
) -> Result<(), Box<dyn Error>>Expand description
Sets up the backup system based on the provided configuration.
This function orchestrates the entire backup setup process, including:
- Installing necessary backup tools
- Configuring the backup schedule
- Setting up backup locations
It creates a snapshot before starting the setup process for potential rollback.
§Arguments
config- A reference to theConfigstruct containing backup configurationrollback- A reference to theRollbackManagerfor creating snapshots
§Returns
Returns Ok(()) if the backup system is set up successfully, or an error if setup fails.