create_local_snapshots¶
Read in configuration file and create local snapshots.
- snapintime.create_local_snapshots.create_snapshot(date_suffix: str, subvol: str, backup_location: str)¶
Create a btrfs snapshot.
- Parameters
date_suffix – a datetime object formatted to be the name of the snapshot
subvol – The subvolume to be snapshotted
backup_location – The folder in which to create the snapshot
- snapintime.create_local_snapshots.get_date_time() str ¶
Return the current time, uses system time zone.
- snapintime.create_local_snapshots.iterate_configs(date_time: str, config: dict) list ¶
Iterate over all the subvolumes in the config file, then call create_snapshot.
- Parameters
date_time – The date time that will end up as the btrfs snapshot name
config – The config file, parsed by import_config.
- Returns
A list containing return values from create_snapshot
- snapintime.create_local_snapshots.main()¶