Revision 0292883e snf-cyclades-app/synnefo/api/ports.py
b/snf-cyclades-app/synnefo/api/ports.py | ||
---|---|---|
44 | 44 |
|
45 | 45 |
from synnefo.api import util |
46 | 46 |
from synnefo.db.models import NetworkInterface |
47 |
from synnefo.logic import servers |
|
47 |
from synnefo.logic import servers, ips
|
|
48 | 48 |
|
49 | 49 |
from logging import getLogger |
50 | 50 |
|
... | ... | |
141 | 141 |
ipaddress = util.get_floating_ip_by_address(user_id, fixed_ip_address, |
142 | 142 |
for_update=True) |
143 | 143 |
elif fixed_ip_address: |
144 |
ipaddress = util.allocate_ip(network, user_id,
|
|
145 |
address=fixed_ip_address)
|
|
144 |
ipaddress = ips.allocate_ip(network, user_id,
|
|
145 |
address=fixed_ip_address) |
|
146 | 146 |
|
147 | 147 |
device_id = api.utils.get_attribute(port_dict, "device_id", required=False) |
148 | 148 |
vm = None |
Also available in: Unified diff