sbin/sync_blinkster
changeset 0 0d40e90630ef
child 7 92ccb522e945
equal deleted inserted replaced
-1:000000000000 0:0d40e90630ef
       
     1 #!/usr/bin/env bash
       
     2 set -e
       
     3 if [ -d ~/tmp/blinkster_V$1 ]; then
       
     4     rm -fr ~/tmp/blinkster_V$1;
       
     5 fi
       
     6 
       
     7 svn export file:///iridata/svn/blinkster/tags/V$1/web ~/tmp/blinkster_V$1
       
     8 
       
     9 #text2unix ~/tmp/blinkster_V$1
       
    10 
       
    11 if [ -d ~/tmp/blinkster_V$1 ]; then
       
    12     cat <<EOT | rsync -Cvrlz --delete --filter=". -" ~/tmp/blinkster_V$1/ web.iri.centrepompidou.fr:/iridata/www/web/blinkster/
       
    13 P .htpasswd
       
    14 P .htaccess
       
    15 P blinkster/.htaccess
       
    16 P blinkster/config.py
       
    17 P robots.txt
       
    18 P log/***
       
    19 P index/***
       
    20 P static/media/***
       
    21 EOT
       
    22 fi
       
    23 
       
    24 if [ -d ~/tmp/blinkster_V$1 ]; then
       
    25     echo "Deleting temp export"
       
    26     rm -fr ~/tmp/blinkster_V$1;
       
    27 fi
       
    28 
       
    29 ssh web.iri.centrepompidou.fr sudo apache2ctl restart