diff options
Diffstat (limited to 'prep-boot-floppy-and-ks-config')
-rwxr-xr-x | prep-boot-floppy-and-ks-config | 32 |
1 files changed, 11 insertions, 21 deletions
diff --git a/prep-boot-floppy-and-ks-config b/prep-boot-floppy-and-ks-config index 298bdbd..c452d3a 100755 --- a/prep-boot-floppy-and-ks-config +++ b/prep-boot-floppy-and-ks-config @@ -195,24 +195,6 @@ function check_options { print_usage exit 1 fi - if [ "x${SecIP}" = "x" ] - then - echo "${Self}: --sec-ip is mandatory" - print_usage - exit 1 - fi - if [ "x${SecNM}" = "x" ] - then - echo "${Self}: --sec-nm is mandatory" - print_usage - exit 1 - fi - if [ "x${SecGW}" = "x" ] - then - echo "${Self}: --sec-gw is mandatory" - print_usage - exit 1 - fi if [ "x${CosmosHash}" = "x" ] then CosmosHash="2ea14b0b958fdc70ad37e3cb9b4185b3648137b8" @@ -254,14 +236,22 @@ TmpDir=$(mktemp -d) ScriptPath=$(echo $0 | sed -e "s#/${Self}##") #echo $ScriptPath +# only add 'secondary interface' options, if they're all there: +if [ -z ${SecIP} ] || [ -z ${SecNM} ] || [ -z ${SecGW} ] +then + SecIfOpts="" +else + SecIfOpts="--sec-ip ${SecIP} --sec-nm ${SecNM} --sec-gw ${SecGW}" +fi + ${ScriptPath}/create-boot-floppy -D ${Domain} -G ${GW} -H ${Host} \ -I ${IP} -M ${NM} -T ${TmpDir} -P ${PublishPath} ${InstCmdLineOpt} \ --gen-cmd ${SelfCommandLine} ${ScriptPath}/adapt-ks-template -D ${Domain} -G ${GW} -H ${Host} \ - -I ${IP} -M ${NM} -T ${TmpDir} -P ${PublishPath} --sec-ip ${SecIP} \ - --sec-nm ${SecNM} --sec-gw ${SecGW} ${TemplateOpt} ${KrnlCmdLineOpt} \ - ${CosmosTagOpt} --gen-cmd ${SelfCommandLine} --boot-dev "${BootDev}" \ + -I ${IP} -M ${NM} -T ${TmpDir} -P ${PublishPath} ${SecIfOpts} \ + ${TemplateOpt} ${KrnlCmdLineOpt} ${CosmosTagOpt} \ + --gen-cmd ${SelfCommandLine} --boot-dev "${BootDev}" \ --root-dev "${RootDev}" # When this script calls the other two, PublishPath *is* set, so expect |