[PATCH] add checksums for mirrors

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Signed-off-by: Florian Pritz <bluewind@xxxxxxx>
---
 db-update |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/db-update b/db-update
index 418c680..6ee6232 100755
--- a/db-update
+++ b/db-update
@@ -238,6 +238,12 @@ for current_arch in ${ARCHES[@]}; do
 				fi
 			done
 		fi
+		# generate syncsums for mirrors
+		md5sum <<< $(md5sum $(find "$FTP_BASE/$reponame/" -type f -name "$reponame$DBEXT") \
+		  | cut -d\  -f1) | cut -d\  -f1 > "$FTP_BASE/$reponame/syncsum"
+		md5sum <<< $(cat "$FTP_BASE/"*"/syncsum") \
+		  | cut -d\  -f1 > "$FTP_BASE/syncsum"
+
 		if ! /bin/cp "$WORKDIR/build/$reponame$DBEXT" "$ftppath/"; then
 			die "failed to move repository $reponame-$current_arch".
 		fi
-- 
1.7.0.4


[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux