This is an automated email from the ASF dual-hosted git repository.
rohit pushed a commit to branch 4.13
in repository https://gitbox.apache.org/repos/asf/cloudstack.git
The following commit(s) were added to refs/heads/4.13 by this push:
new ab02cf7 router: adding "data-server" dns entry in /etc/hosts (#4319)
ab02cf7 is described below
commit ab02cf70789aafde4186c6f07f9407b8f1553923
Author: Lucas Granet <[email protected]>
AuthorDate: Tue Sep 22 09:37:56 2020 +0200
router: adding "data-server" dns entry in /etc/hosts (#4319)
The DNS entry "data-server" was not added in /etc/hosts.
Since the VR is now considered as a "dhcpsrvr" (?), we need to apply this
commit to add this DNS entry.
/etc/hosts is fully rewritten by this script.
Fixes: #4308
(cherry picked from commit dc65f31f9f3cb47240946c8c1cced44a7ecf9640)
Signed-off-by: Rohit Yadav <[email protected]>
---
systemvm/debian/opt/cloud/bin/cs/CsDhcp.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/systemvm/debian/opt/cloud/bin/cs/CsDhcp.py
b/systemvm/debian/opt/cloud/bin/cs/CsDhcp.py
index 7586372..3a8d98f 100755
--- a/systemvm/debian/opt/cloud/bin/cs/CsDhcp.py
+++ b/systemvm/debian/opt/cloud/bin/cs/CsDhcp.py
@@ -158,7 +158,7 @@ class CsDhcp(CsDataBag):
self.add_host("::1", "localhost ip6-localhost ip6-loopback")
self.add_host("ff02::1", "ip6-allnodes")
self.add_host("ff02::2", "ip6-allrouters")
- if self.config.is_router():
+ if self.config.is_router() or self.config.is_dhcp():
self.add_host(self.config.address().get_guest_ip(), "%s
data-server" % CsHelper.get_hostname())
def write_hosts(self):