Merge pull request #2082 from Accelerite/CS-51003

CLOUDSTACK-9017 : VPC VR DHCP broken for multihomed guest VMs
This commit is contained in:
Rajani Karuturi 2017-05-25 09:41:07 +05:30 committed by GitHub
commit eac2d85076
2 changed files with 2 additions and 15 deletions

View File

@ -460,3 +460,5 @@ log-facility=/var/log/dnsmasq.log
# Include a another lot of configuration options.
#conf-file=/etc/dnsmasq.more.conf
conf-dir=/etc/dnsmasq.d
dhcp-optsfile=/etc/dhcpopts.txt

View File

@ -21,7 +21,6 @@ from netaddr import *
def merge(dbag, data):
search(dbag, data['host_name'])
# A duplicate ip address wil clobber the old value
# This seems desirable ....
if "add" in data and data['add'] is False and \
@ -33,17 +32,3 @@ def merge(dbag, data):
dbag[data['ipv4_adress']] = data
return dbag
def search(dbag, name):
"""
Dirty hack because CS does not deprovision hosts
"""
hosts = []
for o in dbag:
if o == 'id':
continue
print "%s %s" % (dbag[o]['host_name'], name)
if dbag[o]['host_name'] == name:
hosts.append(o)
for o in hosts:
del(dbag[o])