diff -Nru duplicity-0.8.18/bin/duplicity duplicity-0.8.19/bin/duplicity --- duplicity-0.8.18/bin/duplicity 2021-01-09 17:50:18.000000000 +0000 +++ duplicity-0.8.19/bin/duplicity 2021-04-29 18:20:20.000000000 +0000 @@ -56,39 +56,6 @@ sys.stderr = codecs.getwriter(u'utf-8')(sys.stderr, u'replace') -if u'--pydevd' in sys.argv or os.getenv(u'PYDEVD', None): - # modify this for your configuration. - # client = base path in machine that Liclipse is on - # server = base path in machine that duplicity is on - client = u'/Users/ken/workspace/duplicity-git' - server = u'/home/ken/workspace/duplicity-git' - - # relative paths under duplicity root - duppaths = [ - u'', - u'bin', - u'duplicity', - u'duplicity/backends', - u'testing', - u'testing/functional', - u'testing/unit', - ] - pathlist = [(os.path.normpath(os.path.join(client, p)), - os.path.normpath(os.path.join(server, p))) for p in duppaths] - os.environ[u'PATHS_FROM_ECLIPSE_TO_PYTHON'] = json.dumps(pathlist) - - import pydevd # pylint: disable=import-error - pydevd.settrace(u'dione.local', port=5678, stdoutToServer=True, stderrToServer=True) - - # In a dev environment the path is screwed so fix it. - base = sys.path.pop(0) - base = base.split(os.path.sep)[:-1] - base = os.path.sep.join(base) - sys.path.insert(0, base) - -log.setup() - - def with_tempdir(fn): u""" Execute function and guarantee cleanup of tempdir is called @@ -108,12 +75,15 @@ if __name__ == u"__main__": try: + util.start_debugger() + # import cProfile # import pstats # import StringIO # prof = cProfile.Profile() # prof.enable(subcalls=True, builtins=True) + log.setup() with_tempdir(main) # prof.disable() diff -Nru duplicity-0.8.18/bin/duplicity.1 duplicity-0.8.19/bin/duplicity.1 --- duplicity-0.8.18/bin/duplicity.1 2021-01-09 17:50:18.000000000 +0000 +++ duplicity-0.8.19/bin/duplicity.1 2021-04-29 18:20:20.000000000 +0000 @@ -1146,6 +1146,9 @@ will be reused instead. Otherwise, if passphrase is needed but not set the user will be prompted for it. +Other environment variables may be used to configure specific backends. +See the notes for the particular backend. + .SH URL FORMAT Duplicity uses the URL format (as standard as possible) to define data locations. The generic format for a URL is: @@ -1203,6 +1206,15 @@ b2://account_id[:application_key]@bucket_name/[folder/] .RE .PP +.BR "Box" +.PP +.RS +box:///some_dir[?config=path_to_config] +.PP +See also +.B "A NOTE ON BOX ACCESS" +.RE +.PP .BR "Cloud Files" " (Rackspace)" .PP .RS @@ -1294,6 +1306,7 @@ .PP .RS megav2://user[:password]@mega.nz/some_dir +megav3://user[:password]@mega.nz/some_dir[?no_logout=1] (For latest MEGAcmd) .PP .B NOTE: despite "MEGAcmd" no longer uses a configuration file, for convenience storing the user password this backend searches it in the $HOME/.megav2rc file (same syntax as the old $HOME/.megarc) @@ -1418,6 +1431,16 @@ below. .RE .PP +.BR "gdrive" +.PP +.RS +gdrive://@developer.gserviceaccount.com/some_dir +.PP +See also +.B "A NOTE ON GDRIVE BACKEND" +below. +.RE +.PP .BR "multi" .PP .RS @@ -1758,22 +1781,22 @@ See Amazon's documentation for details. .SH A NOTE ON AZURE ACCESS -The Azure backend requires the Microsoft Azure Storage SDK for Python to be -installed on the system. +The Azure backend requires the Microsoft Azure Storage Blobs client library +for Python to be installed on the system. See -.B REQUIREMENTS -above. +.BR REQUIREMENTS . + +It uses the environment variable +.BR AZURE_CONNECTION_STRING " (required)." +This string contains all necessary information such as Storage Account name +and the key for authentication. +You can find it under Access Keys for the storage account. -It uses environment variables for authentification: -.BR AZURE_ACCOUNT_NAME " (required)," -.BR AZURE_ACCOUNT_KEY " (optional), -.BR AZURE_SHARED_ACCESS_SIGNATURE " (optional)." -One of -.BR AZURE_ACCOUNT_KEY " or" -.BR AZURE_SHARED_ACCESS_SIGNATURE " is required." +Duplicity will take care to create the container when performing the backup. +Do not create it manually before. -A container name must be a valid DNS name, conforming to the following naming -rules: +A container name (as given as the backup url) must be a valid DNS name, +conforming to the following naming rules: .RS .IP 1. @@ -1792,13 +1815,49 @@ .IR .RE +These rules come from Azure; see +https://docs.microsoft.com/en-us/rest/api/storageservices/naming-and-referencing-containers--blobs--and-metadata + +.SH A NOTE ON BOX ACCESS +The box backend requires boxsdk with jwt support to be installed on the system. +See +.BR REQUIREMENTS . + +It uses the environment variable +.BR BOX_CONFIG_PATH " (optional)." +This string contains the path to box custom app's config.json. Either this environment variable or +the +.BR config +query parameter in the url need to be specified, if both are specified, query paramter takes precedence. + +.SS Create a Box custom app +In order to use box backend, user need to create a box custom app in the box developer console (https://app.box.com/developers/console). + +After create a new custom app, please make sure it is configured as follow: + +.RS +.IP 1. +Choose "App Access Only" for "App Access Level" +.IR +.IP 2. +Check "Write all files and folders stored in Box" +.IR +.IP 3. +Generate a Public/Private Keypair +.IR +.RE + +The user also need to grant the created custom app permission in the +admin console (https://app.box.com/master/custom-apps) by clicking +the "+" button and enter the client_id which can be found on the custom +app's configuration page. + .SH A NOTE ON CLOUD FILES ACCESS Pyrax is Rackspace's next-generation Cloud management API, including Cloud Files access. The cfpyrax backend requires the pyrax library to be installed on the system. See -.B REQUIREMENTS -above. +.BR REQUIREMENTS . Cloudfiles is Rackspace's now deprecated implementation of OpenStack Object Storage protocol. Users wishing to use Duplicity with Rackspace @@ -1806,8 +1865,7 @@ The backend requires python-cloudfiles to be installed on the system. See -.B REQUIREMENTS -above. +.BR REQUIREMENTS . It uses three environment variables for authentification: .BR CLOUDFILES_USERNAME " (required)," @@ -1937,7 +1995,8 @@ https://code.google.com/apis/console#:storage:legacy .SH A NOTE ON HUBIC -The hubic backend requires the pyrax library to be installed on the system. See REQUIREMENTS above. +The hubic backend requires the pyrax library to be installed on the system. See +.BR REQUIREMENTS . You will need to set your credentials for hubiC in a file called ~/.hubic_credentials, following this pattern: .PP @@ -2060,8 +2119,7 @@ .SH A NOTE ON PYDRIVE BACKEND The pydrive backend requires Python PyDrive package to be installed on the system. See -.B REQUIREMENTS -above. +.BR REQUIREMENTS . There are two ways to use PyDrive: with a regular account or with a "service account". With a service account, a separate account is @@ -2114,6 +2172,46 @@ Duplicity. The credentials are then cached in the file references above for future use. +.SH A NOTE ON GDRIVE BACKEND +GDrive: is a rewritten PyDrive: backend with less dependencies, and a +simpler setup - it uses the JSON keys downloaded directly from Google +Cloud Console. + +There are two ways to use GDrive: with a regular account or with a +"service account". With a service account, a separate account is +created, that is only accessible with Google APIs and not a web login. +With a regular account, you can store backups in your normal Google +Drive. + +To use a service account, go to the Google developers console at +https://console.developers.google.com. Create a project, and make sure +Drive API is enabled for the project. In the "Credentials" section, +click "Create credentials", then select Service Account with JSON key. + +The GOOGLE_SERVICE_JSON_FILE environment variable needs to contain the +path to the JSON file on duplicity invocation. + +The alternative is to use a regular account. To do this, start as +above, but when creating a new Client ID, select "Create OAuth client +ID", with application type of "Desktop app". Download the +client_secret.json file for the new client, and set the +GOOGLE_CLIENT_SECRET_JSON_FILE environment variable to the path to +this file, and GOOGLE_CREDENTIALS_FILE to a path to a file where +duplicity will keep the authentication token - this location must be +writable. + +During the first run, you will be prompted to visit an URL in your +browser to grant access to your drive. Once granted, you will receive +a verification code to paste back into Duplicity. The credentials are +then cached in the file references above for future use. + +As a sanity check, GDrive checks the host and username from the URL +against the JSON key, and refuses to proceed if the addresses do not +match. Either the email (for the service accounts) or Client ID (for +regular OAuth accounts) must be present in the URL. See +.B URL FORMAT +above. + .SH A NOTE ON RCLONE BACKEND Rclone is a powerful command line program to sync files and directories to and from various cloud storage providers. .PP @@ -2171,8 +2269,8 @@ is a complete reimplementation of ssh protocols natively in python. Advantages are speed and maintainability. Minor disadvantage is that extra packages are needed as listed in -.B REQUIREMENTS -above. In +.BR REQUIREMENTS . +In .I sftp (default) mode all operations are done via the according sftp commands. In .I scp @@ -2252,8 +2350,7 @@ The backend requires python-switclient to be installed on the system. python-keystoneclient is also needed to use OpenStack's Keystone Identity service. See -.B REQUIREMENTS -above. +.BR REQUIREMENTS . It uses following environment variables for authentification: .BR SWIFT_USERNAME " (required)," @@ -2286,8 +2383,7 @@ python-keystoneclient is also needed to interact with OpenStack's Keystone Identity service. See -.B REQUIREMENTS -above. +.BR REQUIREMENTS . It uses following environment variables for authentification: .BR PCA_USERNAME " (required)," @@ -2424,14 +2520,18 @@ .B python-requests-oauthlib - https://github.com/requests/requests-oauthlib .TP -.BR "azure backend" " (Azure Blob Storage Service)" -.B Microsoft Azure Storage SDK for Python -- https://pypi.python.org/pypi/azure-storage/ +.BR "azure backend" " (Azure Storage Blob Service)" +.B Microsoft Azure Storage Blobs client library for Python +- https://pypi.org/project/azure-storage-blob/ .TP .BR "boto backend" " (S3 Amazon Web Services, Google Cloud Storage)" .B boto version 2.0+ - http://github.com/boto/boto .TP +.BR "box backend" " (box.com)" +.B boxsdk +- https://github.com/box/box-python-sdk +.TP .BR "cfpyrax backend" " (Rackspace Cloud) and " "hubic backend" " (hubic.com)" .B Rackspace CloudFiles Pyrax API - http://docs.rackspace.com/sdks/guide/content/python.html @@ -2462,7 +2562,7 @@ .B megatools client - https://github.com/megous/megatools .TP -.BR "MEGA v2 backend (works for all MEGA accounts)" " (mega.nz)" +.BR "MEGA v2 and v3 backend (works for all MEGA accounts)" " (mega.nz)" .B MEGAcmd client - https://mega.nz/cmd .TP @@ -2478,6 +2578,9 @@ - http://www.ncftp.com/ .TP .BR "OneDrive backend" " (Microsoft OneDrive)" +.B python-requests +- http://python-requests.org +.br .B python-requests-oauthlib - https://github.com/requests/requests-oauthlib .TP diff -Nru duplicity-0.8.18/CHANGELOG.md duplicity-0.8.19/CHANGELOG.md --- duplicity-0.8.18/CHANGELOG.md 2021-01-09 17:50:18.000000000 +0000 +++ duplicity-0.8.19/CHANGELOG.md 2021-04-29 18:20:20.000000000 +0000 @@ -1,9 +1,253 @@ +## rel.0.8.19 (2021-04-29) + +### New + +* Merge branch 'google-drive-v3' into 'master' [Kenneth Loafman] + + Add a new Google Drive backend (gdrive:) + + See merge request duplicity/duplicity!41 + +### Changes + +* Remove installs common between before\_script: and script: [Kenneth Loafman] + +* Remove installs common between before\_script: and script: [Kenneth Loafman] + +### Fix + +* Gdata module passes on py27 only. [Kenneth Loafman] + +* Util.uexec() will return u'' if no err msg in e.args. [Kenneth Loafman] + +* Util.uexec() should check for e==None on entry. [Kenneth Loafman] + +* Fix bug #1547458 - more consistent passphrase prompt. [Kenneth Loafman] + +* Fixes bug #1454136 - SX backend issues. [Kenneth Loafman] + +* Fixes bug 1918981 - option to skip trash on delete on mediafire. [Kenneth Loafman] + + Added --mf-purge option to bypass trash + +* Fix bug 1919017 - MultiBackend reports failure on file deletion. [Kenneth Loafman] + +* Fixes #41 - par2+rsync (non-ssh) fails. [Kenneth Loafman] + +### Other + +* Merge branch 'develop' into 'master' [Kenneth Loafman] + + Fix Google Drive timeout + + See merge request duplicity/duplicity!51 + +* Fix "Giving up after 5 attempts. timeout: The read operation timed out" [Christian Perreault] + +* Merge branch 'master' into 'master' [Kenneth Loafman] + + Don't sync when removing old backups + + See merge request duplicity/duplicity!50 + +* Don't sync when removing old backups. [Matthew Marting] + +* Merge branch 'fix-uexec-returns-None' into 'master' [Kenneth Loafman] + + fix util.uexc: do not return None + + See merge request duplicity/duplicity!49 + +* Fix util.uexc: do not return None. [Michael Kopp] + +* Merge branch 'boxbackend' into 'master' [Kenneth Loafman] + + Implement Box backend + + See merge request duplicity/duplicity!48 + +* Implement Box backend. [Jason Wu] + +* Merge branch 'megav3' into 'master' [Kenneth Loafman] + + Implement megav3 backend to to cater for change in MEGACmd + + See merge request duplicity/duplicity!47 + +* Implement megav3 backend to to cater for change in MEGACmd. [Jason Wu] + +* Merge branch 'master' of git@gitlab.com:duplicity/duplicity.git. [Kenneth Loafman] + +* Merge branch 'use-new-azure-python-packages' into 'master' [Kenneth Loafman] + + fix documentation for azure backend + + See merge request duplicity/duplicity!46 + +* Fix documentation for azure backend. [Michael Kopp] + +* Merge branch 'master' into 'master' [Kenneth Loafman] + + Fix typo + + See merge request duplicity/duplicity!45 + +* Fix typo. [Moses Miller] + +* Merge branch 'master' into 'master' [Kenneth Loafman] + + Add IDrive backend + + See merge request duplicity/duplicity!43 + +* Add IDrive backend. [SmilingM] + +* Merge branch 'master' into 'master' [Kenneth Loafman] + + Progress bar improvements + + Closes #49 + + See merge request duplicity/duplicity!44 + +* Progress bar improvements. [Moses Miller] + +* Fix;usr:Fixes bug #1652953 - seek(0) on /dev/stdin crashes. [Kenneth Loafman] + +* Add a new Google Drive backend (gdrive:) [Jindřich Makovička] + + - Removes the PyDrive/PyDrive2 dependencies, and depends only on the + Google API client libraries commonly available in distributions. + + - Uses unchanged JSON secret files as downloaded from GCP + + - Updates the Google Drive API to V3 + +* Merge branch 'azurev12' into 'master' [Kenneth Loafman] + + Azurev12 + + See merge request duplicity/duplicity!40 + +* Replaced original azure implementation. [Erwin Bovendeur] + +* Fixed code smells. [Erwin Bovendeur] + +* Azure v12 support. [Erwin Bovendeur] + +* Revert "fix:pkg:Remove requirement for python3-pytest-runner. Not used." [Kenneth Loafman] + + This reverts commit 90e7e2acb6d158437cab3210114da46df72a7c85. + +* Merge branch 'feature/list-required-volumes-on-restore-dry-run' into 'master' [Kenneth Loafman] + + List required volumes when called with 'restore --dry-run' + + See merge request duplicity/duplicity!38 + +* List required volumes when called with 'restore --dry-run' [Matthias Blankertz] + + When restoring in dry-run mode, and with the manifest available, list + the volumes that would be gotten from the backend when actually + performing the operation. + This is intended to aid users of e.g. the S3 backend with (deep) glacier + storage, allowing the following workflow to recover files, optionally at + a certain time, from a long-term archive: + 1. duplicity restore --dry-run [--file-to-restore ] [--time