sbin/sync/sync_ldt_platform
author wakimd
Wed, 22 Dec 2010 12:01:05 +0100
changeset 25 c8dfd7ea87e5
parent 1 3a30d255c235
permissions -rwxr-xr-x
Corrections on merge
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     1
#!/usr/bin/env bash
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     2
set -e
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     3
if [ -d ~/tmp/leezam_V$1 ]; then
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     4
    rm -fr ~/tmp/leezam_V$1;
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     5
fi
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     6
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     7
hg archive -r V$1 ~/tmp/leezam_V$1
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     8
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
     9
#text2unix ~/tmp/leezam_V$1
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    10
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    11
if [ -d ~/tmp/leezam_V$1 ]; then
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    12
    cat <<EOT | rsync -Cvrlz --delete --filter=". -" ~/tmp/leezam_V$1/web/ iri@web.iri.centrepompidou.fr:/iridata/www/exp/leezam/
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    13
+ core
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    14
P .htpasswd
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    15
P .htaccess
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    16
P leezam/.htaccess
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    17
P leezam/config.py
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    18
P leezam/modwsgi.wsgi
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    19
P robots.txt
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    20
P env/***
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    21
P log/***
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    22
P index/***
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    23
P static/media/***
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    24
EOT
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    25
fi
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    26
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    27
if [ -d ~/tmp/leezam_V$1 ]; then
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    28
    echo "Deleting temp export"
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    29
    rm -fr ~/tmp/leezam_V$1;
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    30
fi
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    31
3a30d255c235 First version of API with tests
wakimd
parents:
diff changeset
    32
ssh iri@web.iri.centrepompidou.fr sudo apache2ctl restart