Alan Pevec
2008-Apr-11 07:36 UTC
[Ovirt-devel] [PATCH] Error out early if tftpboot exists.
Jim Meyering wrote:> If you put that code in the definition of the create_iso function, > users of ovirt-cd.sh, ovirt-flash.sh, and ovirt-flash-static.sh scripts > will benefit, too.But only ovirt-pxe.sh cares about tftpboot/ right? Otherwise we're fine since iso filename includes timestamp.>> diff --git a/ovirt-host-creator/ovirt-pxe.sh b/ovirt-host-creator/ovirt-pxe.sh >> index 8db83bf..022eec9 100755 >> --- a/ovirt-host-creator/ovirt-pxe.sh >> +++ b/ovirt-host-creator/ovirt-pxe.sh >> @@ -28,6 +28,12 @@ else >> exit 1 >> fi >> >> +if [ -e tftpboot ]; then >> + echo "tftboot/ directory already exists! Cowardly not overwriting."^^^ p missing>> + echo "Please rename or delete old version prior to running this script." >> + exit 1 >> +fi >> +
Jim Meyering
2008-Apr-11 08:34 UTC
[Ovirt-devel] [PATCH] Error out early if tftpboot exists.
Alan Pevec <apevec at redhat.com> wrote:> Jim Meyering wrote: >> If you put that code in the definition of the create_iso function, >> users of ovirt-cd.sh, ovirt-flash.sh, and ovirt-flash-static.sh scripts >> will benefit, too. > > But only ovirt-pxe.sh cares about tftpboot/ right? > Otherwise we're fine since iso filename includes timestamp.Yep. Silly me. Thanks Alan. Sorry, Ian ;-)>>> diff --git a/ovirt-host-creator/ovirt-pxe.sh b/ovirt-host-creator/ovirt-pxe.sh >>> index 8db83bf..022eec9 100755 >>> --- a/ovirt-host-creator/ovirt-pxe.sh >>> +++ b/ovirt-host-creator/ovirt-pxe.sh >>> @@ -28,6 +28,12 @@ else >>> exit 1 >>> fi >>> >>> +if [ -e tftpboot ]; then >>> + echo "tftboot/ directory already exists! Cowardly not overwriting." > ^^^ p missing >>> + echo "Please rename or delete old version prior to running this script." >>> + exit 1 >>> +fi >>> +