Revision e57893cd snf-cyclades-app/synnefo/api/networks.py
b/snf-cyclades-app/synnefo/api/networks.py | ||
---|---|---|
306 | 306 |
if net.machines.all(): # Nics attached on network |
307 | 307 |
raise faults.NetworkInUse('Machines are connected to network.') |
308 | 308 |
|
309 |
if net.floating_ips.filter(deleted=False).exists(): |
|
310 |
raise faults.NetworkInUse("Network has allocated floating IP addresses") |
|
311 |
|
|
309 | 312 |
net.action = 'DESTROY' |
310 | 313 |
net.save() |
311 | 314 |
|
Also available in: Unified diff