Revision 8ac8898f kamaki/clients/network/__init__.py
b/kamaki/clients/network/__init__.py | ||
---|---|---|
180 | 180 |
return r.json['subnets'] |
181 | 181 |
|
182 | 182 |
def get_subnet_details(self, subnet_id): |
183 |
r = self.subnets_get(subnet_id, success=201)
|
|
183 |
r = self.subnets_get(subnet_id, success=200)
|
|
184 | 184 |
return r.json |
185 | 185 |
|
186 | 186 |
def update_subnet( |
... | ... | |
250 | 250 |
port['fixed_ips'] = fixed_ips |
251 | 251 |
if security_groups: |
252 | 252 |
port['security_groups'] = security_groups |
253 |
r = self.ports_post(json_data=dict(port=port), success=201)
|
|
253 |
r = self.ports_post(json_data=dict(port=port), success=200)
|
|
254 | 254 |
return r.json['port'] |
255 | 255 |
|
256 | 256 |
def create_ports(self, ports): |
... | ... | |
280 | 280 |
assert port.get('network_id', None), msg |
281 | 281 |
except AssertionError as ae: |
282 | 282 |
raise ValueError('%s' % ae) |
283 |
r = self.ports_post(json_data=dict(ports=list(ports)), success=201)
|
|
283 |
r = self.ports_post(json_data=dict(ports=list(ports)), success=200)
|
|
284 | 284 |
return r.json['ports'] |
285 | 285 |
|
286 | 286 |
def get_port_details(self, port_id): |
287 |
r = self.ports_get(port_id, success=201)
|
|
287 |
r = self.ports_get(port_id, success=200)
|
|
288 | 288 |
return r.json['port'] |
289 | 289 |
|
290 | 290 |
def delete_port(self, port_id): |
... | ... | |
318 | 318 |
port['fixed_ips'] = fixed_ips |
319 | 319 |
if security_groups: |
320 | 320 |
port['security_groups'] = security_groups |
321 |
r = self.ports_put(port_id, json_data=dict(port=port), success=201)
|
|
321 |
r = self.ports_put(port_id, json_data=dict(port=port), success=200)
|
|
322 | 322 |
return r.json['port'] |
323 | 323 |
|
324 | 324 |
def list_floatingips(self): |
Also available in: Unified diff