Giter VIP home page Giter VIP logo

word-up's Introduction

About
=====
A very simple set of cron-based backup scripts. 'backup.py' creates a backup,
and 'backup_cleanup.py' removes old backups.  Being very simple, it has no
concept of anything but the N last backups. What makes it especially simple
to use is that it picks up how to back up your database from your wordpress
config itself - there is nothing to configure, apart from pointing the 
backup tool to the right directory. 

The backup tool creates a zip file containing your wordpress files,
the wordpress config (but not the wordpress install), and a database dump. 
This is everything you need to restore a previous backup, or migrate the site
somewhere else. 


Requirements 
============
argparse, fs, filepath. These are all are pip installable. I suggest
setting up a virtual env.


Usage
=====
Command line flags and help:
python backup.py --help
python backup_cleanup.py --help


To back up a wordpress install:
python backup.py /var/www/yourwordpress.com /home/you/backups
python backup_cleanup.py /home/you/backups/
I suggest scheculing these via cron. 


To restore from a backup zip file:
1) Unzip the backup file. 
2) Restore the DB
user@linux:~/backup/db> mysql -h mysqlhostserver -u mysqlusername
 -p databasename < blog.bak.sql
3) Restore files: 
Copy the files into your wordpress install. 
Copy the config file into the wordpress install.


Contact information
===================
Created by Rikard Anglerud <[email protected]>.


License
=======
GPLv3 or later. 

word-up's People

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.