docs: add generation of the base tar.gz to the FAQ
[grml-live.git] / buildd / upload_isos.sh
index 9f709dd..04e3cea 100755 (executable)
@@ -1,10 +1,36 @@
 #!/bin/sh
-. main.sh || exit 1
+# Filename:      /usr/share/grml-live/buildd/upload_isos.sh
+# Purpose:       upload grml ISOs to a rsync server
+# 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.
+################################################################################
+
+. /etc/grml/grml-buildd.conf || exit 1
+[ -n "$RSYNC_MIRROR" ] || exit 2
+[ -n "$ISO_DIR" ] || exit 3
+
+cd $ISO_DIR || exit 4
+
 umask 002
-cd /srv/grml-isos || exit 1
 for file in *.iso ; do
-    [ -f "${file}.md5" ] || md5sum $file > ${file}.md5
-    chmod 664 $file
-    chmod 664 ${file}.md5
+    [ -f "${file}.md5" ]  || md5sum "$file" > "${file}".md5
+    [ -f "${file}.sha1" ] || sha1sum "$file" > "${file}".sha1
+    chmod 664 "${file}" "${file}".md5 "${file}".sha1
 done
-rsync --partial -az --quiet $ISO_DIR/* grml-build@debian.netcologne.de:/home/ftp/www.grml.org/daily/
+
+for distri in lenny squeeze sid ; do
+  for flavour in grml-small_$distri   grml-medium_$distri   grml_$distri \
+                 grml64-small_$distri grml64-medium_$distri grml64_$distri ; do
+                 if ls $flavour* 1>/dev/null 2>&1 ; then
+                   rsync --times --partial -az --quiet $flavour* $RSYNC_MIRROR/$flavour/
+                 fi
+  done
+done
+
+#for flavour in grml-small_lenny grml-small_squeeze grml-small_sid grml-medium_lenny grml-medium_sid grml_sid grml_lenny \
+#               grml64-small_lenny grml64-small_sid grml64-medium_lenny grml64-medium_sid grml64_sid grml64_lenny ; do
+#    rsync --times --partial -az --quiet $flavour* $RSYNC_MIRROR/$flavour/
+#done
+
+## END OF FILE #################################################################