26 | | * Data is 1st synced from Prod (''tbc'') |
| 26 | * Data is 1st synced from Prod: |
| 27 | {{{ |
| 28 | /root/automysqlbackup.sh |
| 29 | scp /backups/daily/haitiprod/haitiprod_2010-01-27_01h24m.Wednesday.sql.gz flavour@haiti-dev.sahanafoundation.org:. |
| 30 | |
| 31 | gunzip haitiprod_2010-01-27_01h24m.Wednesday.sql.gz |
| 32 | sed 's/haitiprod/haitidev/g' haitiprod_2010-01-27_01h24m.Wednesday.sql > haitidev_import.sql |
| 33 | vim /etc/crontab |
| 34 | #0-59/1 * * * * www-data cd /home/haiti/web2py/ && python web2py.py -C -D 1 >> /tmp/cron.output 2>&1 |
| 35 | ln -sf /etc/apache2/sites-available/dev-maintain /etc/apache2/sites-enabled/dev |
| 36 | /etc/init.d/apache2 force-reload |
| 37 | mysql |
| 38 | drop DATABASE haitidev; |
| 39 | \q |
| 40 | mysql < haitidev_import.sql |
| 41 | }}} |