summaryrefslogtreecommitdiffstats
path: root/bin/sync-siduction.sh
blob: 997e0ece8ff30052712b7c432e14bce9b4c1cd89 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/bash

RSYNC="/usr/bin/rsync"
#-a = -prtlgoD
OPTS="-prtlvH --delete-after --delay-updates --safe-links"
SRC="rsync://sync.siduction.org:/siduction"
DST="/mirror/ftp/pub/siduction/"

lockfile=/tmp/`basename $0`.lock

if lockfile -r 5 $lockfile
then
	${RSYNC} ${OPTS} ${SRC} ${DST}
	echo "End: "`date`
	rm -f $lockfile
fi