Skip to content

Cloudbox Backup and Restore Scheduling

Chaz Larson edited this page Jul 26, 2020 · 12 revisions

This page will assist you in scheduling Cloudbox backups to run periodically. This is set via Cron.

There are 2 ways to set this up:

  1. Have Cloudbox set it up for you, or

  2. Create a Cron task, manually.

Scheduling Backup via Cloudbox

  1. Make sure settings are filled out, see the here.

  2. Set the schedule:

    1. Go into your Cloudbox folder.

      cd ~/cloudbox
    2. Run the backup command.

      sudo ansible-playbook cloudbox.yml --tags set-backup

Scheduling Backup Manually via Cron

  1. Edit the crontab for the user.

    crontab -e
  2. To add in your cron task, add the following after your desired cron schedule (replace seed with your user name):

    sudo PATH='/usr/bin:/bin:/usr/local/bin' env ANSIBLE_CONFIG='/home/seed/cloudbox/ansible.cfg' '/usr/local/bin/ansible-playbook' '/home/seed/cloudbox/cloudbox.yml' --tags settings >> '/home/seed/logs/cloudbox_backup.log' 2>&1; sudo PATH='/usr/bin:/bin:/usr/local/bin' env ANSIBLE_CONFIG='/home/seed/cloudbox/ansible.cfg' '/usr/local/bin/ansible-playbook' '/home/seed/cloudbox/backup.yml' --tags backup >> '/home/seed/logs/cloudbox_backup.log' 2>&1
    

    Note: If you modify the one that Ansible creates automatically, you must remove/replace the comment header: (#Ansible: Cloudbox Backup), or else Ansible will keep resetting it.

  3. Examples:

    • Weekly (At Midnight Every Sunday):

      @weekly sudo PATH='/usr/bin:/bin:/usr/local/bin' env ANSIBLE_CONFIG='/home/seed/cloudbox/ansible.cfg' '/usr/local/bin/ansible-playbook' '/home/seed/cloudbox/cloudbox.yml' --tags settings >> '/home/seed/logs/cloudbox_backup.log' 2>&1; sudo PATH='/usr/bin:/bin:/usr/local/bin' env ANSIBLE_CONFIG='/home/seed/cloudbox/ansible.cfg' '/usr/local/bin/ansible-playbook' '/home/seed/cloudbox/backup.yml' --tags backup >> '/home/seed/logs/cloudbox_backup.log' 2>&1
      
    • At 6:00 AM Every Morning:

      0 6 * * * sudo PATH='/usr/bin:/bin:/usr/local/bin' env ANSIBLE_CONFIG='/home/seed/cloudbox/ansible.cfg' '/usr/local/bin/ansible-playbook' '/home/seed/cloudbox/cloudbox.yml' --tags settings >> '/home/seed/logs/cloudbox_backup.log' 2>&1; sudo PATH='/usr/bin:/bin:/usr/local/bin' env ANSIBLE_CONFIG='/home/seed/cloudbox/ansible.cfg' '/usr/local/bin/ansible-playbook' '/home/seed/cloudbox/backup.yml' --tags backup >> '/home/seed/logs/cloudbox_backup.log' 2>&1
      
    • For more scheduling examples, visit https://crontab.guru/.

Basics

  1. Introduction
  2. Cloudbox Install Types
  3. Cloudbox Paths
  4. Accessing Cloudbox Apps

Prerequisites

  1. Overview
  2. Presumptions
  3. Server
  4. Domain Name
  5. Cloudflare
  6. Cloud Storage
  7. Plex / Emby - Account
  8. Usenet vs. BitTorrent

Install Cloudbox

Cloudbox
  1. Overview
  2. Dependencies (Choose only one of these)
  3. Settings
  4. Preinstall (Choose only one of these)
  5. SSH
  6. Ansible Vault
  7. Rclone
  8. Cloudbox (Choose only one of these)
  9. Application Setup
    1. NZBGet
    2. ruTorrent
    3. NZBHydra2
    4. Jackett
    5. Plex Media Server
    6. Plex Autoscan
    7. Sonarr
    8. Radarr
    9. Lidarr
    10. PlexPy (Tautulli)
    11. Ombi
    12. Portainer
    13. Organizr
  10. Next Steps

Install Feederbox / Mediabox

Feederbox (do this first)
  1. Overview
  2. Dependencies
  3. Settings
  4. Preinstall
  5. SSH
  6. Ansible Vault
  7. Rclone
  8. Feederbox (Choose only one of these)
  9. Application Setup
    1. NZBGet
    2. ruTorrent
    3. NZBHydra2
    4. Jackett
    5. Sonarr
    6. Radarr
    7. Lidarr
    8. Portainer
    9. Organizr
  10. Next Steps

Mediabox
  1. Overview
  2. Dependencies
  3. Settings
  4. Preinstall
  5. SSH
  6. Ansible Vault
  7. Rclone
  8. Mediabox (Choose only one of these)
  9. Application Setup
    1. Feeder Mount
    2. Plex Media Server
    3. Plex Autoscan
    4. PlexPy (Tautulli)
    5. Ombi
  10. Next Steps

Recommended Reading

Backup and Restore

More Information

Advanced Configuration

Experimental

Extras

Misc

Community-Submitted

See Community Wiki.

Reference

Troubleshooting

Links

Clone this wiki locally