You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Llewellyn van der Merwe 4212d5ee49
Added the option to only do database or website/files incase you only want to do on or the other
4 years ago
.gitignore Started the work of setting the stage for reverting back-up. Also fixed the zip path issue. 4 years ago
LICENSE Initializing system-backup repository 5 years ago
README.md Started the work of setting the stage for reverting back-up. Also fixed the zip path issue. 4 years ago
config.txt Added the option to only do database or website/files incase you only want to do on or the other 4 years ago
databases.txt Initializing system-backup repository 5 years ago
folders.txt Initializing system-backup repository 5 years ago
incl.sh Started the work of setting the stage for reverting back-up. Also fixed the zip path issue. 4 years ago
main.sh Added the option to only do database or website/files incase you only want to do on or the other 4 years ago
run.sh Added the option to only do database or website/files incase you only want to do on or the other 4 years ago
setup.sh Added the option to only do database or website/files incase you only want to do on or the other 4 years ago

README.md

Backup System for server:

The Bash scripts used to backup database and folders on a server

Features

  • Cross platform
  • Fast and effective backups
  • Backup to Dropbox
  • Ability to track changes
  • Historical records
  • Preserve the folder structure
  • Recourse friendly

Getting started

Clone Repository

   $ git clone https://github.com/vdm-io/Backup-System.git Backup-System

Make sure the run file is executable

   $ cd Backup-System/
   $ chmod +x run.sh

Auto Setup Option

Just run :)

   $ ./run.sh

Manual Setup Option

Copy config.txt to config.sh and update the values in the file.

   $ cp config.txt config.sh

Copy folders.txt to folders and update the values in the file.

   $ cp folders.txt folders

Copy databases.txt to databases and update the values in the file.

   $ cp databases.txt databases

Run the script

   $ ./run.sh

Fetch Backup and Restore

Either revert to previous backup (restore) or to do a new deployment.

   $ ./run.sh -r

Tested Environments

  • GNU Linux

If you have successfully tested this script on others systems or platforms please let me know!

Running as cron job

Get the full path to the run.sh file. Open https://crontab.guru to get your cron time settings. Open the crontab:

   $ crontab -e

With your cron time, add the following line to the crontab, using your path details:

5 03 * * * /path/to/run.sh >/dev/null 2>&1

your time | your path | to ignore messages

GIT, BASH

Debian & Ubuntu Linux:

    $ sudo apt-get install bash (Probably BASH is already installed on your system)
    $ sudo apt-get install git

To use the Dropbox back-up option You also need the Dropbox-Uploader:

    $ git clone https://github.com/andreafabrizi/Dropbox-Uploader.git Dropbox-Uploader
    $ cd Dropbox-Uploader/
    $ chmod +x dropbox_uploader.sh
    $ ./dropbox_uploader.sh

Copyright: