host_protections.py revision df062569a6407ec084c4ee05b9390f8a0183d37b
1import enum, global_config
2
3Protection = enum.Enum('No protection',   # Repair can do anything to this host
4                       'Filesystem only', # Repair should only try to
5                                          # recover the file system
6                       'Do not repair'    # Repair should not touch this host
7                       )
8
9default = Protection.get_value(
10    global_config.global_config.get_config_value(
11        'HOSTS', 'default_protection'))
12
13choices = Protection.choices()
14