Skip to content

linuxwhatelse/dups

Folders and files

NameName
Last commit message
Last commit date

Latest commit

34b7b6c · Jan 2, 2022
Aug 7, 2019
Jan 17, 2020
Jan 2, 2022
Sep 26, 2018
Sep 2, 2020
Oct 30, 2019
Sep 21, 2018
Jun 28, 2018
Oct 12, 2018
Aug 22, 2018
Jul 9, 2018
Oct 12, 2018
Oct 12, 2018
Sep 21, 2018
Sep 27, 2018
Oct 1, 2018
Oct 2, 2018

Repository files navigation

dups banner

Say Thanks Build status

Overview

dups is a simple backup utility using rsync for its heavy lifting while adding some convenience on top.

To reduce disk space and subsequent backup times, dups relies on rsyncs --link-dest option which hardlinks to existing unchanged files.

Motivation

Being unable to find a backup utility which would allow me to...

  • backup selected files and folders
  • exclude files and folders based on their path or patterns
  • easily access stored files without special tools
    (This includes the backup software itself)
  • doesn't come with to much bloat

...I ended up writing my own.
This is not to say other software is bad, just not what I was looking for.

Getting Started

See deployment for notes on how to deploy dups on a live system.

Prerequisites

Required system packages:

rsync

Required python packages:

# Runtime
paramiko
ruamel.yaml>=0.15.0

# Runtime (Optional)
dbus-python  # Daemon support
pygobject  # Desktop notification support

# Unittests
pytest

Installing

After all prerequisites have been met, dups can be installed with:

$ git clone https://github.com/linuxwhatelse/dups
$ cd dups
$ python setup.py install

System files for dbus, systemd etc. can be included by setting INCLUDE_DATA_FILES prior to running the installation.
This will require root access to copy the files to their respective location and is therefore ill-advised for live systems.
For live systems, see deployment instead.

$ export INCLUDE_DATA_FILES="systemd dbus desktop"
$ python setup.py install

For possible values see get_data_files in setup.py.

Build files/scripts for some distributions can be found in data/pkg/.

Usage

For a full setup guide and usage examples see the wiki.

As a quick overview, here's dups main help message.
Individual commands may have additional arguments.

usage: dups [-h] [-u [USER]] [-c [CONFIG]] <command> ...

It deduplicates things - Backup as simple as possible.

optional arguments:
  -h, --help            show this help message and exit
  -u [USER], --user [USER]
                        Pretend to be this user for reading the config file,
                        writing logs etc. while preserving the original users
                        access rights. Only useful when run with elevated
                        privileges.
  -c [CONFIG], --config [CONFIG]
                        Use this config file instead.

Commands:
  <command>
    backup (b)          Start a new backup.
    list (l)            List backups.
    info (I)            Retrieve detailed backup info.
    modify (m)          Modify the given backup(s).
    restore (r)         Start a new restore.
    remove (rm)         Remove one or more backups.
    log                 Print backup/restore logs.
    include (i)         List/Add/Remove include items.
    exclude (e)         List/Add/Remove exclude items.
    daemon (d)          Start a daemon instance.

Deployment

Packages for some distributions are automatically built and are available in the release section.

Additionally, the following distributions have a version accessible through their package-manager.

Distribution Link
archlinux aur - python-dups-git

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Authors

  • tadly - Initial work - tadly

Credits

License

This project is licensed under the GNU General Public License v3.0 - see the LICENSE file for details