169 lines
4.8 KiB
Plaintext
169 lines
4.8 KiB
Plaintext
OS = 'general'
|
|
METADATA = {
|
|
'general': {
|
|
'_self': {
|
|
'required_in_whole_config': True
|
|
},
|
|
'language': {
|
|
'_self': {
|
|
'field': 'general',
|
|
'default_value': 'EN',
|
|
'options': ['EN', 'CN'],
|
|
'mapping_to': 'language'
|
|
}
|
|
},
|
|
'timezone': {
|
|
'_self': {
|
|
'field': 'general',
|
|
'default_value': 'UTC',
|
|
'options': [
|
|
'GMT -12:00', 'GMT -11:00', 'GMT -10:00', 'GMT -9:00',
|
|
'GMT -8:00', 'GMT -7:00', 'GMT -6:00', 'GMT -5:00',
|
|
'GMT -4:00', 'GMT -3:00', 'GMT -2:00', 'GMT -1:00',
|
|
'GMT 0:00', 'GMT +1:00', 'GMT +2:00', 'GMT +3:00',
|
|
'GMT +4:00', 'GMT +5:00', 'GMT +6:00', 'GMT +7:00',
|
|
'GMT +8:00', 'GMT +9:00', 'GMT +10:00', 'GMT +11:00',
|
|
'GMT +12:00', 'UTC'
|
|
],
|
|
'mapping_to': 'timezone'
|
|
}
|
|
},
|
|
'http_proxy': {
|
|
'_self': {
|
|
'field': 'general',
|
|
'default_value': 'http://10.145.88.211:3128',
|
|
'options': [
|
|
'http://10.145.88.211:3128'
|
|
],
|
|
'mapping_to': 'http_proxy'
|
|
}
|
|
},
|
|
'https_proxy': {
|
|
'_self': {
|
|
'field': 'general',
|
|
'default_value': 'http://10.145.88.211:3128',
|
|
'options': [
|
|
'http://10.145.88.211:3128'
|
|
],
|
|
'mapping_to': 'https_proxy'
|
|
}
|
|
},
|
|
'no_proxy': {
|
|
'_self': {
|
|
'field': 'general_list',
|
|
'default_value': [
|
|
'127.0.0.1',
|
|
'compass',
|
|
'10.145.88.211'
|
|
],
|
|
'options': [
|
|
'127.0.0.1',
|
|
'compass',
|
|
'10.145.88.211'
|
|
],
|
|
'mapping_to': 'no_proxy'
|
|
}
|
|
},
|
|
'ntp_server': {
|
|
'_self': {
|
|
'is_required': True,
|
|
'field': 'general',
|
|
'default_value': '10.145.88.211',
|
|
'options': [
|
|
'10.145.88.211'
|
|
],
|
|
'mapping_to': 'ntp_server'
|
|
}
|
|
},
|
|
'dns_servers': {
|
|
'_self': {
|
|
'is_required': True,
|
|
'field': 'general_list',
|
|
'default_value': [
|
|
'10.145.88.211',
|
|
],
|
|
'options': [
|
|
'10.145.88.211'
|
|
],
|
|
'mapping_to': 'nameservers'
|
|
}
|
|
},
|
|
'domain': {
|
|
'_self': {
|
|
'field': 'general',
|
|
'is_required' : True,
|
|
'default_value': 'ods.com',
|
|
'options': ['ods.com'],
|
|
}
|
|
},
|
|
'search_path': {
|
|
'_self': {
|
|
'field': 'general_list',
|
|
'default_value': [
|
|
'ods.com'
|
|
],
|
|
'options': ['ods.com'],
|
|
'mapping_to': 'search_path'
|
|
}
|
|
},
|
|
'default_gateway': {
|
|
'_self': {
|
|
'is_required': True,
|
|
'field': 'ip',
|
|
'default_value': '10.145.88.1',
|
|
'mapping_to': 'gateway'
|
|
}
|
|
}
|
|
},
|
|
'server_credentials': {
|
|
'_self': {
|
|
'required_in_whole_config': True,
|
|
'mapping_to': 'server_credentials'
|
|
},
|
|
'username': {
|
|
'_self': {
|
|
'is_required': True,
|
|
'field': 'username',
|
|
'mapping_to': 'username'
|
|
}
|
|
},
|
|
'password': {
|
|
'_self': {
|
|
'is_required': True,
|
|
'field': 'password',
|
|
'mapping_to': 'password'
|
|
}
|
|
}
|
|
},
|
|
'partition': {
|
|
'_self': {
|
|
'required_in_whole_config': True,
|
|
'options': ['/boot', 'swap', '/var', '/home'],
|
|
'mapping_to': 'partition'
|
|
},
|
|
'$partition': {
|
|
'_self': {
|
|
'validator': is_valid_partition
|
|
},
|
|
'max_size': {
|
|
'_self': {
|
|
'field': 'size',
|
|
'mapping_to': 'max_vol_size'
|
|
},
|
|
},
|
|
'percentage': {
|
|
'_self': {
|
|
'field': 'percentage',
|
|
'mapping_to': 'vol_percentage'
|
|
}
|
|
},
|
|
'size': {
|
|
'_self': {
|
|
'field': 'size',
|
|
'mapping_to': 'vol_size'
|
|
},
|
|
}
|
|
}
|
|
}
|
|
}
|