borgbackup/docs/usage/key_add.rst.inc
Thomas Waldmann d5cd72b179 docs: add docs for "key add", "key list" and "key remove"
The multi-key feature (#9743) added the "borg key add", "borg key list"
and "borg key remove" subcommands but never wired up their docs:

- scripts/make.py: map key_add/key_list/key_remove to the "key" usage
  group, so build_man can locate their examples (it previously aborted
  with FileNotFoundError: docs/usage/key_add.rst).
- docs/usage/key.rst: include the three new generated snippets so they
  show up on the HTML key page.
- regenerate the affected docs: new key_{add,list,remove}.rst.inc usage
  snippets, new borg-key-{add,list,remove}.1 man pages, and borg-key.1
  (SYNOPSIS + SEE ALSO now reference the new subcommands).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-13 21:37:21 +02:00

59 lines
No EOL
2.5 KiB
PHP

.. IMPORTANT: this file is auto-generated from borg's built-in help, do not edit!
.. _borg_key_add:
borg key add
------------
.. code-block:: none
borg [common options] key add [options]
.. only:: html
.. class:: borg-options-table
+-------------------------------------------------------+-------------------+---------------------------------------------+
| **options** |
+-------------------------------------------------------+-------------------+---------------------------------------------+
| | ``--label LABEL`` | label for the new borg key (must be unique) |
+-------------------------------------------------------+-------------------+---------------------------------------------+
| .. class:: borg-common-opt-ref |
| |
| :ref:`common_options` |
+-------------------------------------------------------+-------------------+---------------------------------------------+
.. raw:: html
<script type='text/javascript'>
$(document).ready(function () {
$('.borg-options-table colgroup').remove();
})
</script>
.. only:: latex
options
--label LABEL label for the new borg key (must be unique)
:ref:`common_options`
|
Description
~~~~~~~~~~~
A repository can be protected by more than one borg key. Each borg key contains the
same secret key material, but is protected by an independent (potentially different)
passphrase, and any of them can be used to unlock the same repository. This is useful
e.g. to give individual users their own passphrase while keeping a separate
admin/recovery passphrase.
This command adds an additional borg key. It does not re-encrypt any repository data
and does not change the existing borg keys. The new passphrase is read from
``BORG_NEW_PASSPHRASE`` or queried interactively.
Each borg key has a label. The first borg key, created at repository creation time, has
the reserved label ``admin`` and is protected from deletion. Additionally added borg
keys require a unique, user-defined ``--label``.