# Authors: grml-team (grml.org), (c) Michael Prokop <mika@grml.org>
# Bug-Reports: see http://grml.org/bugs/
# License: This file is licensed under the GPL v2 or any later version.
-# Latest change: Wed Oct 24 11:07:47 CEST 2007 [mika]
+# Latest change: Thu Oct 25 22:40:45 CEST 2007 [mika]
################################################################################
die() {
# execute grml-live:
grml_live_run() {
-grml-live -F $GRML_LIVE_ARCH -s $SUITE -c $CLASSES -o $OUTPUT_DIR \
- -g $NAME -v $DATE -r grml-live-autobuild -i $ISO_NAME \
- 1>$GRML_LOGFILES/grml-buildd.stdout \
- 2>$GRML_LOGFILES/grml-buildd.stderr ; RC=$?
-
-if [ "$RC" = "0" ] ; then
- RC_INFO=success
-else
- RC_INFO=error
-fi
+ if [ -f "$ISO_DIR/$ISO_NAME" ] ; then
+ echo "$ISO_DIR/$ISO_NAME exists already. Nothing to be done, exiting."
+ exit 0
+ fi
+
+ grml-live -F $GRML_LIVE_ARCH -s $SUITE -c $CLASSES -o $OUTPUT_DIR \
+ -g $NAME -v $DATE -r grml-live-autobuild -i $ISO_NAME \
+ 1>$GRML_LOGFILES/grml-buildd.stdout \
+ 2>$GRML_LOGFILES/grml-buildd.stderr ; RC=$?
+
+ if [ "$RC" = "0" ] ; then
+ RC_INFO=success
+ else
+ RC_INFO=error
+ fi
}
# create log archive:
create_logs() {
-( cd / && tar zcf $ATTACHMENT var/log/fai/dirinstall/grml 1>/dev/null )
+ ( cd / && tar zcf $ATTACHMENT var/log/fai/dirinstall/grml 1>/dev/null )
}
# store information of ISO size:
iso_details() {
-if ! [ -f "$OUTPUT_DIR/grml_isos/$ISO_NAME" ] ; then
- ISO_DETAILS="There was an error creating $ISO_NAME"
-else
- ISO_DETAILS=$(ls -lh $OUTPUT_DIR/grml_isos/$ISO_NAME)
-fi
+ if ! [ -f "$OUTPUT_DIR/grml_isos/$ISO_NAME" ] ; then
+ ISO_DETAILS="There was an error creating $ISO_NAME"
+ else
+ ISO_DETAILS=$(ls -lh $OUTPUT_DIR/grml_isos/$ISO_NAME)
+ fi
}
# send status mail:
send_mail() {
-echo -en "Automatically generated mail by $SCRIPTNAME
+ echo -en "Automatically generated mail by $SCRIPTNAME
$ISO_DETAILS
$(grep warn $FAI_LOGFILES/* || echo "* nothing")
Find details in the attached logs." | \
-mutt -s "$SCRIPTNAME [${DATE}] - $RC_INFO" \
- -a $ATTACHMENT \
- $RECIPIENT
+ mutt -s "$SCRIPTNAME [${DATE}] - $RC_INFO" \
+ -a $ATTACHMENT \
+ $RECIPIENT
}
# make sure we store the final iso:
grml-live.{stdout,stderr} as log files.
- buildd/functions.sh: do not mv files if there was an error
during grml-live execution
+ - do not re-execute grml-live is the target ISO exists already
* Added new grml-repository named grml-live which is intented
to fix issues from Debian for grml-live builds. It is automatically
activated if you are building against unstable/sid and should
by default.
* Set $SECONDS to unknown if $start_seconds is not set.
* Improve directory handling for $LOGFILE.
+ * Check for presence of /bin/zsh before setting default shell in
+ /etc/grml/fai/config/scripts/GRMLBASE/21-usersetup
* Add new packages to GRML_FULL:
- ldnsutils
- madwifi-modules-2.6.23-grml
# Authors: grml-team (grml.org), (c) Michael Prokop <mika@grml.org>
# Bug-Reports: see http://grml.org/bugs/
# License: This file is licensed under the GPL v2 or any later version.
-# Latest change: Thu Oct 18 19:47:14 CEST 2007 [mika]
+# Latest change: Fri Oct 26 01:22:30 CEST 2007 [mika]
################################################################################
set -u
sed -i 's/^root::/root:*:/' $target/etc/shadow
sed -i "s/^$USERNAME:!:/$USERNAME:*:/" $target/etc/shadow
-$ROOTCMD chsh -s /bin/zsh root
-$ROOTCMD chsh -s /bin/zsh $USERNAME
+if [ -r $target/bin/zsh ] ; then
+ $ROOTCMD chsh -s /bin/zsh root
+ $ROOTCMD chsh -s /bin/zsh $USERNAME
+fi
## END OF FILE #################################################################
# vim:ft=sh expandtab ai tw=80 tabstop=4 shiftwidth=3