Replace all references to ftp.de.debian.org with cdn.debian.org
[grml-live.git] / buildd / upload_isos.sh
1 #!/bin/sh
2 # Filename:      /usr/share/grml-live/buildd/upload_isos.sh
3 # Purpose:       upload grml ISOs to a rsync server
4 # Authors:       grml-team (grml.org), (c) Michael Prokop <mika@grml.org>
5 # Bug-Reports:   see http://grml.org/bugs/
6 # License:       This file is licensed under the GPL v2 or any later version.
7 ################################################################################
8
9 . /etc/grml/grml-buildd.conf || exit 1
10 [ -n "$RSYNC_MIRROR" ] || exit 2
11 [ -n "$ISO_DIR" ] || exit 3
12
13 cd $ISO_DIR || exit 4
14
15 umask 002
16 for file in *.iso ; do
17     [ -f "${file}.md5" ]  || md5sum "$file" > "${file}".md5
18     [ -f "${file}.sha1" ] || sha1sum "$file" > "${file}".sha1
19     chmod 664 "${file}" "${file}".md5 "${file}".sha1
20 done
21
22 for distri in lenny squeeze sid ; do
23   for flavour in grml-small_$distri   grml-medium_$distri   grml_$distri \
24                  grml64-small_$distri grml64-medium_$distri grml64_$distri ; do
25                  if ls $flavour* 1>/dev/null 2>&1 ; then
26                    rsync --times --partial -az --quiet $flavour* $RSYNC_MIRROR/$flavour/
27                  fi
28   done
29 done
30
31 #for flavour in grml-small_lenny grml-small_squeeze grml-small_sid grml-medium_lenny grml-medium_sid grml_sid grml_lenny \
32 #               grml64-small_lenny grml64-small_sid grml64-medium_lenny grml64-medium_sid grml64_sid grml64_lenny ; do
33 #    rsync --times --partial -az --quiet $flavour* $RSYNC_MIRROR/$flavour/
34 #done
35
36 ## END OF FILE #################################################################