Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions systemvm/debian/etc/vpcdnsmasq.conf
Original file line number Diff line number Diff line change
Expand Up @@ -462,3 +462,4 @@ log-facility=/var/log/dnsmasq.log
conf-dir=/etc/dnsmasq.d

dhcp-optsfile=/etc/dhcpopts.txt
localise-queries
3 changes: 3 additions & 0 deletions systemvm/debian/opt/cloud/bin/cs/CsDhcp.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,9 @@ def configure_server(self):
listen_address.append(gateway)
else:
listen_address.append(ip)
# Add localized "data-server" records in /etc/hosts for VPC routers
if self.config.is_vpc():
self.add_host(gateway, "%s data-server" % CsHelper.get_hostname())

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this can only work if we know for sure that CsHelper.get_hostname() gives an ip address and no hostname, are we?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this can only work if we know for sure that CsHelper.get_hostname() gives an ip address and no hostname, are we?

@DaanHoogland
CsHelper.get_hostname() gives the hostname of virtual router. As you can see in screenshot, 'r-24-VM' is the hostname. So it should return hostname, not IP.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry, never mind, I mis-interpreted the semantics of add_host(). no ip needed in that parameter, a (list of) hosts-name(s) is fine.

idx += 1

# Listen Address
Expand Down