summaryrefslogtreecommitdiffstats
path: root/defaultenv/defaultenv-2-base/init/automount
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2014-02-20 10:19:25 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2014-02-21 17:06:50 +0100
commitb850dbad6557c4cd0e03c9b83be88579412cdd3f (patch)
tree482bf33f0f795da74243167520c9794523abad6f /defaultenv/defaultenv-2-base/init/automount
parent464a531423f61b5d2c5108843e12ab7057a935bb (diff)
downloadbarebox-b850dbad6557c4cd0e03c9b83be88579412cdd3f.tar.gz
move defaultenv-2 to defaultenv/defaultenv-2-*
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'defaultenv/defaultenv-2-base/init/automount')
-rw-r--r--defaultenv/defaultenv-2-base/init/automount22
1 files changed, 22 insertions, 0 deletions
diff --git a/defaultenv/defaultenv-2-base/init/automount b/defaultenv/defaultenv-2-base/init/automount
new file mode 100644
index 0000000..fe56d92
--- /dev/null
+++ b/defaultenv/defaultenv-2-base/init/automount
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+if [ "$1" = menu ]; then
+ init-menu-add-entry "$0" "Automountpoints"
+ exit
+fi
+
+# automount tftp server based on $eth0.serverip
+
+mkdir -p /mnt/tftp
+automount /mnt/tftp 'ifup eth0 && mount -t tftp $eth0.serverip /mnt/tftp'
+
+# automount nfs server example
+
+#nfshost=somehost
+#mkdir -p /mnt/${nfshost}
+#automount /mnt/$nfshost "ifup eth0 && mount -t nfs ${nfshost}:/tftpboot /mnt/${nfshost}"
+
+# FAT on usb disk example
+
+#mkdir -p /mnt/fat
+#automount -d /mnt/fat 'usb && [ -e /dev/disk0.0 ] && mount /dev/disk0.0 /mnt/fat'