backups

A module to manage backups

denver

denver

3,323 downloads

3,323 latest version

4.6 quality score

Version information

  • 0.1.0 (latest)
released Jan 24th 2019
This version is compatible with:
  • CentOS
    ,
    Ubuntu

Start using this module

Documentation

denver/backups — version 0.1.0 Jan 24th 2019

base

Build Status Code Coverage Puppet Forge Puppet Forge - downloads Puppet Forge - scores

Table of Contents

  1. Description
  2. Usage - Configuration options and additional functionality
  3. Development

Description

This module will deploy a user to execute backups and a cron job to create encrypted backup artifacts.

Usage

Linux

Backing up a directory

class { '::backups':
  gpg_keyfile => 'pubkey.gpg'
  gpg_keyid   => 'keyname'
}

backups::backup { 'service-name':
  backup_type => 'file',
  backup_file => '/etc/conf/dir', 
  cron_hour   => 1,
  cron_minute => 30,
}

Backing up a postgres database.

class { '::backups':
  gpg_keyfile => 'pubkey.gpg'
  gpg_keyid   => 'keyname'
}

backups::backup { 'postgresdbname':
  backup_type => 'pg_db',
  backup_db   => 'dbname',
}

Backing up a mysql database.

class { '::backups':
  gpg_keyfile => 'pubkey.gpg'
  gpg_keyid   => 'keyname'
}

backups::backup { 'mysqldbname':
  backup_type => 'mysql_db',
  backup_db   => 'dbname',
}

Development

When adding to this module, be sure to add and update the unit tests where appropriate. You can run the tests locally with the following commands...

To execute general tests (lint, validate, spec)

bundle install
bundle exec rake test