Commit ee507bae authored by Christos Stavrakakis's avatar Christos Stavrakakis
Browse files

Use 'network' instead of 'link'

- Rename GANETI_PUBLIC_LINK to GANETI_PUBLIC_NETWORK
- modify create_instance of backend module
parent 9f6c6233
......@@ -23,7 +23,7 @@ POLL_LIMIT = 3600
# Synnefo assigns this link id to NICs connected on the public network.
# An IP pool should be associated with this link by the Ganeti administrator.
GANETI_PUBLIC_LINK = 'snf_public'
GANETI_PUBLIC_NETWORK = 'snf_public'
# This link id is assigned to NICs that should be isolated from anything else
# (e.g., right before the NIC gets deleted).
# This value is also hardcoded in a fixture in db/fixtures/initial_data.json.
......
......@@ -221,10 +221,10 @@ def start_action(vm, action):
def create_instance(vm, flavor, image, password, personality):
"""`image` is a dictionary which should contain the keys:
'backend_id', 'format' and 'metadata'
metadata value should be a dictionary.
"""
nic = {'ip': 'pool', 'mode': 'routed', 'link': settings.GANETI_PUBLIC_LINK}
nic = {'ip': 'pool', 'network': settings.GANETI_PUBLIC_NETWORK}
if settings.IGNORE_FLAVOR_DISK_SIZES:
if image['backend_id'].find("windows") >= 0:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment