Révision 353560b3
Ajouté par Julien Enselme il y a environ 10 ans
other-scripts/d7-sync.sh | ||
---|---|---|
64 | 64 |
### sync databases |
65 | 65 |
now=$(date +%s) |
66 | 66 |
sql_file="$1.$now.sql" |
67 |
remote_sql_file="~/tmp/$sql_file"
|
|
67 |
remote_sql_file="$REMOTE_DIR_TMP_SAS/$sql_file"
|
|
68 | 68 |
assos "drush @$1 sql-dump > $remote_sql_file" |
69 |
scp_from_assos $remote_sql_file .
|
|
69 |
scp $SSH_ID_SAS:$remote_sql_file .
|
|
70 | 70 |
mysql -u root -e "DROP DATABASE IF EXISTS $local_db_name; CREATE DATABASE $local_db_name" |
71 | 71 |
ret=$? |
72 | 72 |
if [ $ret -ne 0 ] ; then |
Formats disponibles : Unified diff
SQL file is dumped on sas