1.3.0 • Published 3 years ago

@swordev/arestic-cli v1.3.0

Weekly downloads
7
License
MIT
Repository
github
Last release
3 years ago

arestic-cli

CLI tool for automatic restic backups.

Features

  • Config profiles
    • Repositories
    • Backups
    • Forgets
  • File config JSON/YAML format
  • Auto init repositories
  • Path globs
  • Custom snapshot date by path regex capture
  • Logging file
  • Cross-platform

Install

npm install -g @swordev/arestic-cli

Usage

Usage: npx arestic [options] [command]

Options:
  -c, --config-path <value>  Config path (default: "arestic.{json,yaml,yml}:$HOME/arestic.{json,yaml,yml}")
  -h, --help                 display help for command

Commands:
  parse                      Parse config
  backup [options]           Create snapshots
  forget [options]           Forget snapshots
  help [command]             display help for command

Config schema

https://github.com/swordev/arestic-cli/blob/main/arestic.schema.json

Config examples

Single repository

repositories:
  local:
    backend: local
    path: /var/data/restic
backups:
  user:
    password: SECRET
    repositories:
      - local
    paths:
      - /home/user
    options:
      tag:
        - data

Multiple repository

repositories:
  remote-base:
    backend: rest
    protocol: http
    host: 127.0.0.1
    port: 8000
  remote:
    extends: remote-base
    username: username
    password: SECRET
    path: /username
  local:
    backend: local
    path: /var/data/restic
backups:
  user:
    passwordPath: /var/secret/password-restic
    repositories:
      - remote
      - local
    paths:
      - /home/user
    options:
      tag:
        - data

Custom snapshot date

repositories:
  local:
    backend: local
    path: /var/data/restic
backups:
  backups:
    repositories:
      - local
    password: SECRET
    snapshotByPath: true
    pathGlobs:
      - patterns: /var/data/backups/*
        onlyDirectories: true
    pathRegexes:
      - backup-(?<date>[\d\-]+)$
    regexDateFormat: YYYY-MM-DD-HH-mm-ss
1.3.0

3 years ago

1.2.0

3 years ago

1.2.1

3 years ago

1.1.1

3 years ago

1.1.0

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago