summaryrefslogtreecommitdiffstats
path: root/remote/modules
diff options
context:
space:
mode:
authorSimon Rettberg2013-06-20 17:17:06 +0200
committerSimon Rettberg2013-06-20 17:17:06 +0200
commit13ffab4b775974a486370f924f7744058e88df99 (patch)
tree89f9bc3d2bd9fc99c07c1bb870d02d0b670534f2 /remote/modules
parent[redsocks] Make it work more good and less bad (diff)
downloadtm-scripts-13ffab4b775974a486370f924f7744058e88df99.tar.gz
tm-scripts-13ffab4b775974a486370f924f7744058e88df99.tar.xz
tm-scripts-13ffab4b775974a486370f924f7744058e88df99.zip
[vmplayer] Wait for host's udhcpc to write DNS servers to config before generating udhcpd config
Diffstat (limited to 'remote/modules')
-rwxr-xr-xremote/modules/vmplayer/data/etc/openslx/vmware/vmware-env7
1 files changed, 7 insertions, 0 deletions
diff --git a/remote/modules/vmplayer/data/etc/openslx/vmware/vmware-env b/remote/modules/vmplayer/data/etc/openslx/vmware/vmware-env
index d35e7635..feff5135 100755
--- a/remote/modules/vmplayer/data/etc/openslx/vmware/vmware-env
+++ b/remote/modules/vmplayer/data/etc/openslx/vmware/vmware-env
@@ -14,6 +14,13 @@ export PATH=$PATH:/opt/openslx/bin:/opt/openslx/sbin:/opt/openslx/usr/bin:/opt/o
VMWARE_CONF_DIR=/etc/openslx/vmware
+for wait in 1 1 2 2 3 end; do
+ grep '^SLX_DNS' /opt/openslx/config > /dev/null && break
+ [ "$wait" == "end" ] && echo "No DNS config found, using google dns" && break
+ echo "Waiting for DNS config.."
+ sleep "$wait"
+done
+
#source config file
. /opt/openslx/config
. ${VMWARE_CONF_DIR}/vmware.conf