Forge Home

autorestic

pdk
Install, manage and configure backup tool restic and autorestic from Github releases

649 downloads

227 latest version

5.0 quality score

Version information

  • 1.0.0 (latest)
  • 0.0.2
  • 0.0.1
released Nov 20th 2021
This version is compatible with:
  • Puppet Enterprise 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x, 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x, 2019.0.x
  • Puppet >= 6.0.0 < 8.0.0
  • Debian
    ,
    Ubuntu

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'rehan-autorestic', '1.0.0'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add rehan-autorestic
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install rehan-autorestic --version 1.0.0

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.

Download

Documentation

rehan/autorestic — version 1.0.0 Nov 20th 2021

rehan-autorestic

Puppet Forge Build Status

Table of Contents

  1. Overview
  2. Module Description
  3. Setup
  4. Usage
  5. Dependencies
  6. Development

Overview

The rehan-autorestic installs & manages autorestic and restic, tools to back up and restore data to various local and cloud storage solutions. More information can be found on their respective sites.

Module Description

This module can create/manage a new user account for backup and restore using autorestic for scripting the backup locations and backends. It can install system-wide and restricted copies of restic binary with file read capability that allows autorestic user to back up read all system files without root access.

More information on this can be found at:

Setup

In order to install rehan-autorestic, run the following command:

$ puppet module install rehan-autorestic

The module does expect all the data to be provided through 'Hiera'. See Usage for examples on how to configure it.

Usage

Classes

autorestic

A basic install with the defaults would be:

include autorestic

And the default hiera settings are:

autorestic::account_manage: true
autorestic::account_ensure: present
autorestic::account_name: 'autorestic'
autorestic::account_gid: '990'
autorestic::account_uid: '990'
autorestic::account_home: '/var/lib/autorestic'
autorestic::account_groups: []

autorestic::dependencies_manage: true
autorestic::dependencies_packages:
   - bzip2

autorestic::architecture: "%{facts.os.architecture}"
autorestic::os_type: 'linux'

autorestic::restic_ensure: present
autorestic::restic_version: '0.12.1'
autorestic::restic_download_file_extension: "bz2"
autorestic::restic_download_filename: "restic_%{lookup('autorestic::restic_version')}_%{lookup('autorestic::os_type')}_%{lookup('autorestic::architecture')}"
autorestic::restic_download_url: "https://github.com/restic/restic/releases/download/v%{lookup('autorestic::restic_version')}/%{lookup('autorestic::restic_download_filename')}.%{lookup('autorestic::restic_download_file_extension')}"
autorestic::restic_checksum: '11d6ee35ec73058dae73d31d9cd17fe79661090abeb034ec6e13e3c69a4e7088'
autorestic::restic_checksum_type: sha256
autorestic::restic_global_install_directory: '/opt/restic'
autorestic::restic_global_install_ensure: absent

autorestic::autorestic_ensure: present
autorestic::autorestic_version: '1.5.0'
autorestic::autorestic_download_file_extension: "bz2"
autorestic::autorestic_download_filename: "autorestic_%{lookup('autorestic::autorestic_version')}_%{lookup('autorestic::os_type')}_%{lookup('autorestic::architecture')}"
autorestic::autorestic_download_url: "https://github.com/cupcakearmy/autorestic/releases/download/v%{lookup('autorestic::autorestic_version')}/%{lookup('autorestic::autorestic_download_filename')}.%{lookup('autorestic::autorestic_download_file_extension')}"
autorestic::autorestic_checksum: '823c4b766f289d5d1a40fea52a6f4f1fbd4071ca6e57c74b88e57e0649cbaeaf'
autorestic::autorestic_checksum_type: sha256
autorestic::autorestic_install_directory: '/opt/autorestic'

autorestic::wrapper_user: "%{lookup('autorestic::account_name')}"

Dependencies

Development

You can submit pull requests and create issues through the official page of this module: https://github.com/rehan/puppet-autorestic. Please do report any bug and suggest new features/improvements.