introduce staticroute tagtype
[myplc.git] / db-config.d / 03-interfacesettings
1 #################### interface settings
2 # xxx this should move to PLC/Accessors
3
4 # Setup default slice attribute types
5 setting_types = \
6 [
7     {'category' : "interface/general",
8      'tagname' : "ifname",
9      'description': "Set interface name, instead of eth0 or the like",
10      'min_role_id' : 40},
11
12     {'category' : "interface/route",
13      'tagname' : "staticroute",
14      'description': "Set static route for interfaces",
15      'min_role_id' : 40},
16
17     {'category' : "interface/multihome",
18      'tagname' : "alias",
19      'description': "Specifies that the network is used for multihoming",
20      'min_role_id' : 40},
21     
22     {'category' : "interface/hidden",
23      'tagname' : "backdoor",
24      'description': "For testing new settings",
25      'min_role_id' : 10},
26     ] + [
27
28     { 'category' : "interface/wifi",
29       'tagname' : x,
30       'description' : "802.11 %s -- see %s"%(y,z),
31       'min_role_id' : 40 } for (x,y,z) in [
32
33     ("mode","Mode","iwconfig"),
34
35     ("essid","ESSID","iwconfig"),
36
37     ("nw","Network Id","iwconfig"),
38
39     ("freq","Frequency","iwconfig"),
40
41     ("channel","Channel","iwconfig"),
42
43     ("sens","sensitivity threshold","iwconfig"),
44
45     ("rate","Rate","iwconfig"),
46
47     ("key","key","iwconfig key"),
48
49     ("key1","key1","iwconfig key [1]"),
50
51     ("key2","key2","iwconfig key [2]"),
52
53     ("key3","key3","iwconfig key [3]"),
54
55     ("key4","key4","iwconfig key [4]"),
56
57     ("securitymode","Security mode","iwconfig enc"),
58
59     ("iwconfig","Additional parameters to iwconfig","ifup-wireless"),
60
61     ("iwpriv","Additional parameters to iwpriv","ifup-wireless"),
62
63     ]
64     ]
65
66 for setting_type in setting_types:
67     SetTagType(setting_type)