Skip to content
Snippets Groups Projects
Name Last commit Last update
defaults
files
handlers
meta
tasks
tests
vars
README.md

itopie.rsnapshot-client

This role prepare clients to be backuped by an rsnapshot server

Requirements

  • The Backup Server User SSH key must be set in the backupuser_ssh_key variable

Role Variables

  • backupuser_ssh_key: the Backup User SSH public key. There's no default value. If the value is not supplied, the insert task will be skipped.
  • backup_user_create: Create user if it doesn't exist
  • backup_user: username of the new backup user
  • backup_user_uid: uid of the new backup user
  • backup_user_full_sudo: True if the new user must have full sudo power

Example Playbook

---
- hosts: backupclients
  become: yes
  vars:
    backup_user_create: True
    backup_user: backupuser
    backup_user_id: 10000
    backup_user_full_sudo: True
  tasks:
  - include_vars: my_secrete_vars.yml
  - import_role:
      name: itopie.rsnapshot-client

Backup SQL script

Database Backup script is deployed to /var/local/bin/backup-sql.sh

use backup-sql.sh -h to see usage and an exemple

Don't forget to manually add a cron for daily backups, the playbook do not.

License

BSD

Author Information

Jonathan Blum jblum@itopie.ch - https://www.itopie.ch