1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-01-11 05:17:41 +03:00

Merge branch 'feature-2391'

This commit is contained in:
Ruben S. Montero 2013-11-12 22:57:24 +01:00
commit 3238b0d915
2 changed files with 8 additions and 1 deletions

View File

@ -18,7 +18,7 @@
export DNS_VARIABLES="DNS $(env | sed 's/=.*$//' | grep -E '^ETH[0-9]+_DNS$' | sort)"
export SEARCH_VARIABLES="SEARCH $(env | sed 's/=.*$//' | grep -E '^ETH[0-9]+_SEARCH$' | sort)"
export SEARCH_VARIABLES="SEARCH_DOMAIN $(env | sed 's/=.*$//' | grep -E '^ETH[0-9]+_SEARCH_DOMAIN$' | sort)"
nameservers=$(
for var in ${DNS_VARIABLES}; do
@ -49,3 +49,4 @@ done
[ -z "$searchdomains" ] && exit 0
echo search $searchdomains >> /etc/resolv.conf

View File

@ -731,6 +731,12 @@ int VirtualMachine::parse_context(string& error_str)
val << "$NETWORK[DNS, NETWORK=\"" << name << "\"]";
context->replace(var.str(), val.str());
var.str(""); val.str("");
var << "ETH" << nic_id << "_SEARCH_DOMAIN";
val << "$NETWORK[SEARCH_DOMAIN, NETWORK=\"" << name << "\"]";
context->replace(var.str(), val.str());
if (!ip6.empty())
{
var.str(""); val.str("");