iankelling.org
/
git
/
automated-distro-installer
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
warn of new upstream basefiles
[automated-distro-installer]
/
myfai-chboot
diff --git
a/myfai-chboot
b/myfai-chboot
index 32addc589e4f2a2b9455ec4d48b47ff39c5dc40c..2a6e02590d2a7fc6e59ce50521db6ac44a1dcf91 100755
(executable)
--- a/
myfai-chboot
+++ b/
myfai-chboot
@@
-3,22
+3,23
@@
set -eE -o pipefail
trap 'echo "$0:$LINENO:error: \"$BASH_COMMAND\" returned $?" >&2' ERR
set -eE -o pipefail
trap 'echo "$0:$LINENO:error: \"$BASH_COMMAND\" returned $?" >&2' ERR
+x=$(readlink -f "$BASH_SOURCE"); cd ${x%/*}
usage() {
usage() {
- cat <<
'EOF'
-usage
$0 [hostname|ip|default]...
+ cat <<
EOF
+usage
: ${0##*/} [-h|--help] [hostname|ip]
-Sets up tftp pxe config. No argument disables for all hosts.
+Sets up tftp pxe config and nfs config on host "faiserver". Argument
+sets the host to enable it for. No argument disables pxe config for all
+hosts, but leaves nfs server alone. Use faiserver-disable to disable
+the nfs server.
EOF
exit $1
}
EOF
exit $1
}
+case $1 in
+ -h|--help) usage ;;
+esac
-cd "${BASH_SOURCE%/*}" # directory of the script
host=$(chost faiserver)
ssh root@$host bash -s "$@" <myfai-chboot-local
host=$(chost faiserver)
ssh root@$host bash -s "$@" <myfai-chboot-local
-if [[ $1 ]]; then
- ./faiserver-enable
-else
- ./faiserver-disable
-fi