{"id":23984595,"url":"https://github.com/tohuwabohu/puppet-duplicity","last_synced_at":"2025-12-11T21:37:06.223Z","repository":{"id":16589198,"uuid":"19343534","full_name":"tohuwabohu/puppet-duplicity","owner":"tohuwabohu","description":"Puppet module to manage backups based on duplicity. ","archived":false,"fork":false,"pushed_at":"2025-11-21T17:57:21.000Z","size":679,"stargazers_count":8,"open_issues_count":2,"forks_count":33,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-11-21T19:26:22.565Z","etag":null,"topics":["backup","duplicity","duply","puppet"],"latest_commit_sha":null,"homepage":null,"language":"Puppet","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tohuwabohu.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2014-05-01T12:14:59.000Z","updated_at":"2025-11-21T17:57:18.000Z","dependencies_parsed_at":"2023-02-13T23:35:18.971Z","dependency_job_id":"53f9842b-4b70-44ff-aa75-d55c297753db","html_url":"https://github.com/tohuwabohu/puppet-duplicity","commit_stats":null,"previous_names":[],"tags_count":54,"template":false,"template_full_name":null,"purl":"pkg:github/tohuwabohu/puppet-duplicity","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tohuwabohu%2Fpuppet-duplicity","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tohuwabohu%2Fpuppet-duplicity/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tohuwabohu%2Fpuppet-duplicity/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tohuwabohu%2Fpuppet-duplicity/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tohuwabohu","download_url":"https://codeload.github.com/tohuwabohu/puppet-duplicity/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tohuwabohu%2Fpuppet-duplicity/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27670498,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-12-11T02:00:11.302Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["backup","duplicity","duply","puppet"],"created_at":"2025-01-07T13:33:43.077Z","updated_at":"2025-12-11T21:37:06.216Z","avatar_url":"https://github.com/tohuwabohu.png","language":"Puppet","funding_links":[],"categories":[],"sub_categories":[],"readme":"# duplicity\n\n[![License](https://img.shields.io/github/license/tohuwabohu/puppet-duplicity.svg)](https://github.com/tohuwabohu/puppet-duplicity/blob/master/LICENSE.txt)\n[![build-and-test](https://github.com/tohuwabohu/puppet-duplicity/actions/workflows/main.yml/badge.svg)](https://github.com/tohuwabohu/puppet-duplicity/actions/workflows/main.yml)\n[![Puppet Forge](https://img.shields.io/puppetforge/v/tohuwabohu/duplicity.svg)](https://forge.puppetlabs.com/tohuwabohu/duplicity)\n[![Puppet Forge - downloads](https://img.shields.io/puppetforge/dt/tohuwabohu/duplicity.svg)](https://forge.puppetlabs.com/tohuwabohu/duplicity)\n\n## Overview\n\nConfigure [duply](http://duply.net/) on top of [duplicity](http://duplicity.nongnu.org/) to provide a profile-based,\neasy to use backup and restore system.\n\n## Usage\n\nInstall duplicity and duply with all default values.\n\n```\nclass { 'duplicity': }\n```\n\nInstall a more recent version of duply from [the sourceforge project page](http://sourceforge.net/projects/ftplicity/)\n\n```\nclass { 'duplicity':\n  duply_package_provider      =\u003e 'archive',\n  duply_archive_version       =\u003e '2.1',\n  duply_archive_checksum      =\u003e 'a8d2bfa907aacbef1c66bf1079fa24e541ad63f5d0694029e4596b030f3cb244',\n  duply_archive_checksum_type =\u003e 'sha256',\n}\n```\n\nSpecify the backup server to be used; see the duplicity documentation for more information about the available protocols.\n\n```\nclass { 'duplicity':\n  backup_target_url      =\u003e 'ftps://backup.example.com/',\n  backup_target_username =\u003e 'username',\n  backup_target_password =\u003e 'password',\n}\n```\n\nIn case you're using duply 1.10+ and a storage backend that requires additional environment variables to be set, use\nthe following pattern\n\n```\nclass { 'duplicity':\n  duply_environment =\u003e [\n    \"export AWS_ACCESS_KEY_ID='${my_access_key}'\",\n    \"export AWS_SECRET_ACCESS_KEY='${my_secret_key}'\",\n  ],\n}\n```\n\nThis works on a profile-level as well.\n\nConfigure a simple backup profile that stops an application before the backup starts and starts it when complete.\nIt will run once a day, do incremental backups by default and create a full backup if the previous full backup\nis older than 7 days. Duplicity will keep at most two full backups and purge older ones.\n\n```\nduplicity::profile { 'system':\n  full_if_older_than  =\u003e '7D',\n  max_full_backups    =\u003e 2,\n  cron_hour           =\u003e '4',\n  cron_minute         =\u003e '0',\n  exec_before_content =\u003e '/bin/systemctl stop myapp',\n  exec_after_content  =\u003e '/bin/systemctl start myapp',\n}\n```\n\nBackup a file and restore it from a previous backup if it is not existing. Setting `ensure` to `backup` will only\nbackup the file but not restore it.\n\n```\nduplicity::file { '/path/to/file':\n  ensure =\u003e present,\n}\n```\n\nA directory will only be restored if the directory is not existing - an empty directory is not replaced. To prevent \nPuppet from accidentally creating an empty directory, explicitly add a dependency between the `duplicity::file` and the\n`file` as shown in the following example. This will ensure the restore process will get a chance to run before the \ndirectory is created.\n\n```\nduplicity::file { $mailman3_data_dir:\n  timeout =\u003e 1800,\n}\n\n-\u003e file { $mailman3_data_dir:\n  ensure =\u003e directory,\n  owner  =\u003e 'list',\n  group  =\u003e 'list',\n  mode   =\u003e '0644',\n}\n```\n\nBackup a directory by using a specific backup profile and exclude a bunch of files.\n\n```\n$data_dir = '/var/lib/jira'\n\nduplicity::file { $data_dir:\n  profile =\u003e 'jira',\n  exclude =\u003e [\n    \"${data_dir}/caches\",\n    \"${data_dir}/tmp\",\n    \"${data_dir}/plugins/.osgi-plugins/felix/felix-cache\",\n    \"${data_dir}/plugins/.osgi-plugins/transformed-plugins\",\n  ],\n}\n```\n\nDefine a GnuPG key pair `BEEF1234` to be used to de/encrypt the backup on the node itself and configure the backup\nprofile to use it. The encrytion key `ALICE00001` is used to decrypt the backup on another node (e.g. the admin's\nworkstation).\n\n```\nduplicity::private_key { 'BEEF1234':\n  content =\u003e hiera('duplicity::private_key::BEEF1234'),\n}\n\nduplicity::public_key { 'BEEF1234':\n  content =\u003e template('path/to/BEEF1234.pub.asc.erb'),\n}\n\nclass { 'duplicity':\n  gpg_encryption_keys =\u003e ['ALICE00001', 'BEEF1234'],\n  gpg_signing_key     =\u003e 'BEEF1234',\n}\n```\n\nOr turn off the encryption of backups for a particular profile altogether:\n\n```\nduplicity::profile { 'system':\n  gpg_encryption =\u003e false,\n}\n```\n\n## Limitations\n\nThe module is primarily tested on the most recent Debian and Ubuntu distributions. See [.github/workflows/main.yml](.github/workflows/main.yml)\nfor the currently tested versions.\n\n## Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Add some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create new Pull Request\n\n### Development\n\nThis project uses rspec-puppet and beaker to ensure the module works as expected and to prevent regressions.\n\n```\ngem install bundler\nbundle install --path vendor\n\nbundle exec rake spec\nbundle exec rake beaker\n```\n(note: see [Beaker - Supported ENV variables](https://github.com/puppetlabs/beaker-rspec/blob/master/README.md) for a\nlist of environment variables to control the default behaviour of Beaker)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftohuwabohu%2Fpuppet-duplicity","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftohuwabohu%2Fpuppet-duplicity","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftohuwabohu%2Fpuppet-duplicity/lists"}