@@ -25,11 +25,13 @@ def list(self):
25
25
u'mgmt_user_info': [
26
26
{
27
27
u'isSystemMonitor': False,
28
+ u'isSecurityAdmin': False,
28
29
u'userId': u'someone@internal',
29
30
u'isSystemAdmin': True
30
31
},
31
32
{
32
33
u'isSystemMonitor': False,
34
+ u'isSecurityAdmin': False,
33
35
u'userId': u'root',
34
36
u'isSystemAdmin': True
35
37
}
@@ -54,6 +56,7 @@ def get(self, user_id):
54
56
u'isSystemMonitor': False,
55
57
u'userId': u'admin',
56
58
u'isSystemAdmin': True
59
+ u'isSecurityAdmin': True
57
60
}
58
61
59
62
:param user_id: User identifier for which local user information needs to
@@ -82,7 +85,7 @@ def delete(self, user_id):
82
85
return self .conn .post (url = 'vdc/users/{}/deactivate' .format (user_id ))
83
86
84
87
def create (self , user_id , password , is_system_admin = False ,
85
- is_system_monitor = False ):
88
+ is_system_monitor = False , is_security_admin = False ):
86
89
"""
87
90
Creates local users for the VDC. These users can be assigned to
88
91
VDC-wide management roles and are not associated with a namespace.
@@ -99,19 +102,22 @@ def create(self, user_id, password, is_system_admin=False,
99
102
the System Admin role. Default: False
100
103
:param is_system_monitor: If set to True, assigns the management user
101
104
to the System Monitor role. Default: False
105
+ :param is_security_admin: If set to True, assigns the management user
106
+ to the Security Admin role. Default: False
102
107
"""
103
108
payload = {
104
109
"userId" : user_id ,
105
110
"password" : password ,
106
111
"isSystemAdmin" : is_system_admin ,
107
- "isSystemMonitor" : is_system_monitor
112
+ "isSystemMonitor" : is_system_monitor ,
113
+ "isSecurityAdmin" : is_security_admin
108
114
}
109
115
110
116
log .info ("Creating local management user '{}'" .format (user_id ))
111
117
return self .conn .post (url = 'vdc/users' , json_payload = payload )
112
118
113
119
def update (self , user_id , password , is_system_admin = False ,
114
- is_system_monitor = False ):
120
+ is_system_monitor = False , is_security_admin = False ):
115
121
"""
116
122
Updates user details for the specified local management user.
117
123
@@ -130,11 +136,14 @@ def update(self, user_id, password, is_system_admin=False,
130
136
the System Admin role. Default: False
131
137
:param is_system_monitor: If set to True, assigns the management user
132
138
to the System Monitor role. Default: False
139
+ :param is_security_admin: If set to True, assigns the management user
140
+ to the Security Admin role. Default: False
133
141
"""
134
142
payload = {
135
143
"password" : password ,
136
144
"isSystemAdmin" : is_system_admin ,
137
- "isSystemMonitor" : is_system_monitor
145
+ "isSystemMonitor" : is_system_monitor ,
146
+ "isSecurityAdmin" : is_security_admin
138
147
}
139
148
140
149
log .info ("Updating local management user '{}'" .format (user_id ))
0 commit comments