summaryrefslogtreecommitdiff
path: root/sys/src/9/boot
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2014-12-10 03:22:14 +0100
committercinap_lenrek <cinap_lenrek@felloff.net>2014-12-10 03:22:14 +0100
commit23b3407663fd2f312760e4ce21443bf4c9e10f5f (patch)
tree15273a6bce2ae8e0cb115bc8465411323f3a7a84 /sys/src/9/boot
parentd75f5a24baa73052dd174fbd84a9615db4551b73 (diff)
bootrc: add ndb/dnsgetip resolver to bootfs so domain names can be used for fs=, auth= and secstore= (thanks mischief)
Diffstat (limited to 'sys/src/9/boot')
-rwxr-xr-xsys/src/9/boot/net.rc7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/src/9/boot/net.rc b/sys/src/9/boot/net.rc
index 63697d8ff..42ba9f19e 100755
--- a/sys/src/9/boot/net.rc
+++ b/sys/src/9/boot/net.rc
@@ -25,6 +25,13 @@ fn confignet{
if(~ $#auth 0)
ask auth ' ip is? ' $fs(1)
+ # resolve dns names
+ if(test -x /bin/ndb/dnsgetip){
+ for(i in fs auth secstore){
+ $i=`{for(x in $$i) ndb/dnsgetip -a $x}
+ }
+ }
+
# set bootstrap authservers for factotum
if(! ~ $#auth 0){
grep -v '^[ ]*auth=' /net/ndb >/env/x