Sinisterly
Restore Site Files With Cron Jobs? - Printable Version

+- Sinisterly (https://sinister.ly)
+-- Forum: Design (https://sinister.ly/Forum-Design)
+--- Forum: Web Design (https://sinister.ly/Forum-Web-Design)
+--- Thread: Restore Site Files With Cron Jobs? (/Thread-Restore-Site-Files-With-Cron-Jobs)



Restore Site Files With Cron Jobs? - 3r3bus - 09-28-2012

Hey guys,

I want to restore a site from a generic backup on a scheduled timer.
My theory is to use cron jobs to execute a php script (on a set time interval) which restores the site from a .tar on the same ftp server as the files.

So it would need to delete all files on the server (except the .tar) then extract the contents of the .tar back onto the server.

Is this possible?
If so, were would I find such a script. I have looked around the interwebz and can't find anything matching my needs, nor do I have the skills to write the script myself.

Cheers.


RE: Restore Site Files With Cron Jobs? - 3r3bus - 10-01-2012

I hate to do this, but BUMP!

Another question:
Is it possible to store the backup on a different server, somehow automatically;
Deletes all files of the server
Downloads the backup .tar from a separate server on to the existing
Extract the .tar

and repeat? Or is that to advanced?


RE: Restore Site Files With Cron Jobs? - 1llusion - 10-01-2012

Hi

You can make a php script that would delete all files from the server, download the backup and extract it Smile can't be that hard Smile I'll try to make it for ya Smile


RE: Restore Site Files With Cron Jobs? - 3r3bus - 10-01-2012

(10-01-2012, 12:01 PM)1llusion Wrote: Hi

You can make a php script that would delete all files from the server, download the backup and extract it Smile can't be that hard Smile I'll try to make it for ya Smile

I love you.


RE: Restore Site Files With Cron Jobs? - bluedog.tar.gz - 10-01-2012

(10-01-2012, 12:06 PM)3r3bu$ Wrote:
(10-01-2012, 12:01 PM)1llusion Wrote: Hi

You can make a php script that would delete all files from the server, download the backup and extract it Smile can't be that hard Smile I'll try to make it for ya Smile

I love you.

Just cron a wget and overwrite it.