@ -0,0 +1,5 @@ |
|||||
|
root@yoda.easy-cloud.net 2203 /etc/opt/djbdns/tinydns/root |
||||
|
root@yoda2.easy-cloud.net 2201 /etc/opt/djbdns/tinydns/root |
||||
|
root@darthbane.easy-cloud.net 2201 /etc/opt/djbdns/tinydns/root |
||||
|
root@atlien.easy-cloud.net 22 /etc/opt/djbdns/tinydns/root |
||||
|
root@koke.easy-cloud.net 2203 /etc/opt/djbdns/tinydns/root |
@ -1,31 +1,17 @@ |
|||||
#!/bin/sh |
#!/bin/sh |
||||
|
|
||||
DIRS= |
|
||||
for x in root/*/Makefile; do |
|
||||
DIRS="$DIRS ${x%/*}" |
|
||||
make -C ${x%/*} |
|
||||
done |
|
||||
|
|
||||
RSYNCOPT="$RSYNCOPT --exclude */*.zone.in" |
|
||||
RSYNCOPT="$RSYNCOPT --exclude .gitignore" |
|
||||
RSYNCOPT="$RSYNCOPT --exclude Makefile" |
|
||||
|
RSYNCOPT="-azOP" |
||||
|
#RSYNCOPT="$RSYNCOPT --exclude */*.zone.in" |
||||
|
#RSYNCOPT="$RSYNCOPT --exclude .gitignore" |
||||
|
RSYNCOPT="$RSYNCOPT --exclude data.cdb" |
||||
#RSYNCOPT="$RSYNCOPT --dry-run" |
#RSYNCOPT="$RSYNCOPT --dry-run" |
||||
RSYNCOPT="$RSYNCOPT --delete --delete-after --delete-excluded" |
|
||||
|
RSYNCOPT="$RSYNCOPT --delete --delete-after" |
||||
|
|
||||
( |
|
||||
cat <<-EOT |
|
||||
root@yoda.easy-cloud.net 2203 /etc/opt/djbdns/tinydns/root |
|
||||
root@yoda2.easy-cloud.net 2201 /etc/opt/djbdns/tinydns/root |
|
||||
root@darthbane.easy-cloud.net 2201 /etc/opt/djbdns/tinydns/root |
|
||||
root@atlien.easy-cloud.net 22 /etc/opt/djbdns/tinydns/root |
|
||||
root@koke.easy-cloud.net 2203 /etc/opt/djbdns/tinydns/root |
|
||||
EOT |
|
||||
) | while read REMOTE PORT DIR; do |
|
||||
|
while read REMOTE PORT DIR; do |
||||
( |
( |
||||
export RSYNC_RSH="ssh -p $PORT" |
export RSYNC_RSH="ssh -p $PORT" |
||||
echo "=== $REMOTE:$PORT ($DIR) ===" |
echo "=== $REMOTE:$PORT ($DIR) ===" |
||||
rsync -a root/Makefile "$REMOTE:$DIR/" |
|
||||
rsync -a $RSYNCOPT $DIRS "$REMOTE:$DIR/" |
|
||||
|
rsync $RSYNCOPT data/stage/ "$REMOTE:$DIR/" && |
||||
ssh -p $PORT $REMOTE make -B -C "$DIR/" data.cdb |
ssh -p $PORT $REMOTE make -B -C "$DIR/" data.cdb |
||||
) < /dev/null |
) < /dev/null |
||||
done |
|
||||
|
done < root/farm.txt |