summaryrefslogtreecommitdiffstats
path: root/repoman/bin
diff options
context:
space:
mode:
authorramon <ramongomez@us.es>2012-04-23 12:22:28 +0000
committerramon <ramongomez@us.es>2012-04-23 12:22:28 +0000
commit89a82089853b78dd54d0b6c7f1d8d9ae03beb56e (patch)
tree143862c3621a8171f811f9e7b413412174b75b3c /repoman/bin
parent0ad88ebde65d0042ba3d893c226d2bc3e2356e0a (diff)
Versión 1.0.4, #414: Pequeñas correcciones en scripts ejecutados por Cron.
git-svn-id: https://opengnsys.es/svn/branches/version1.0@2981 a21b9725-9963-47de-94b9-378ad31fedc9
Diffstat (limited to 'repoman/bin')
-rwxr-xr-xrepoman/bin/opengnsys.cron1
-rwxr-xr-xrepoman/bin/torrent-creator4
2 files changed, 3 insertions, 2 deletions
diff --git a/repoman/bin/opengnsys.cron b/repoman/bin/opengnsys.cron
index db517fbd..76236f73 100755
--- a/repoman/bin/opengnsys.cron
+++ b/repoman/bin/opengnsys.cron
@@ -1,3 +1,4 @@
+#!/bin/bash
# Comprobamos si los servicios de opengnsys están levantado y si no es así los iniciamos.
# Variables.
OPENGNSYS=${OPENGNSYS:-"/opt/opengnsys"}
diff --git a/repoman/bin/torrent-creator b/repoman/bin/torrent-creator
index 21d58581..fe5aebf3 100755
--- a/repoman/bin/torrent-creator
+++ b/repoman/bin/torrent-creator
@@ -36,7 +36,7 @@ for IMG in *.{img,pgz}; do
SUMFILE="$IMG.sum"
if [ -f "$TORRENT" ]; then
FILESIZE="$(ls -l $IMG | awk '{print $5}')"
- read -e TORRFILE TORRSIZE <<<"$(ctorrent -x $TORRENT | awk '$1~/<1>/ {print $2,$3}')"
+ read -e TORRFILE TORRSIZE <<<"$(ctorrent -x $TORRENT 2>/dev/null | awk '$1~/<1>/ {print $2,$3}')"
[ "$(basename $IMG)" = "$TORRFILE" -a "[$FILESIZE]" = "$TORRSIZE" ] && continue
fi
# Bloquear imagen, crear ficheros Torrent y Checksum y desbloquear imagen.
@@ -46,7 +46,7 @@ for IMG in *.{img,pgz}; do
rm -f "$TORRENT" "$SUMFILE"
DATASUM=`md5sum "$IMG" | cut -f1 -d" "`
echo $DATASUM > "$SUMFILE"
- nice -8 ctorrent -t "$IMG" -u $TRACKERURL -s "$TORRENT" -c $DATASUM
+ nice -8 ctorrent -t "$IMG" -u $TRACKERURL -s "$TORRENT" -c $DATASUM 2>/dev/null
rm -f "$LOCKFILE"
if [ -f "$TORRENT" ]; then
echo "`date` : Fin creación de fichero $TORRENT" >> $LOGFILE