How Do I Automatically Update My Database Nightly
Posted
by Russ
on Super User
See other posts from Super User
or by Russ
Published on 2010-05-07T20:09:51Z
Indexed on
2010/05/07
20:18 UTC
Read the original article
Hit count: 288
Currently, every day before I start work, I complete the following procedure:
- ssh to the production server
- gzip our daily database dump file
- scp the gzipped dump file over to my computer
- gunzip the dump file
- dropdb mydatabase
- createdb mydatabase
- psql mydatabase < dump.sql
Is it possible (I'm sure it is) to automate this process on Mac OSX? This way it is done by the time I get to work in the morning. If so, what is the quickest and easiest way?
© Super User or respective owner