attempt to retrieve peer gid within a try/except block
[sfa.git] / config / sfa-config-tty
1 #!/bin/env python
2
3 import sys
4 import readline
5 import plc_config
6
7 def validator(validated_variables):
8     pass
9 #    maint_user = validated_variables["PLC_API_MAINTENANCE_USER"]
10 #    root_user = validated_variables["PLC_ROOT_USER"]
11 #    if maint_user == root_user:
12 #        errStr="PLC_API_MAINTENANCE_USER=%s cannot be the same as PLC_ROOT_USER=%s"%(maint_user,root_user)
13 #        raise plc_config.ConfigurationException(errStr)
14
15 usual_variables = [
16     "SFA_INTERFACE_HRN",
17     "SFA_REGISTRY_ROOT_AUTH",
18     "SFA_REGISTRY_LEVEL1_AUTH",
19     "SFA_REGISTRY_HOST", 
20     "SFA_AGGREGATE_HOST",
21     "SFA_SM_HOST",
22     "SFA_PLC_USER",
23     "SFA_PLC_PASSWORD",
24     "SFA_PLC_DB_HOST",
25     "SFA_PLC_DB_USER",
26     "SFA_PLC_DB_PASSWORD",
27     "SFA_PLC_URL",
28     ]
29
30 configuration={ \
31     'name':'sfa',
32     'service':"sfa",
33     'usual_variables':usual_variables,
34     'config_dir':"/etc/sfa",
35     'validate_variables':{},
36     'validator':validator,
37     }
38
39 if __name__ == '__main__':
40     command=sys.argv[0]
41     argv = sys.argv[1:]
42     plc_config.main(command,argv,configuration)