Files
flan 252696f1de
CI / shell (shellcheck + syntax) (push) Successful in 8s
CI / python 3.11 (push) Successful in 13s
CI / python 3.13 (push) Successful in 14s
CI / python 3.12 (push) Successful in 14s
docs: split the 969-line README; put Install at the top
Install was at line 517 of 969, under the boot sequence, the snapshot lifecycle and
the release process. Someone deciding whether to trust this with their backups should
not have to scroll past any of that.

README is now 211 lines: what it does, the minimum version, install, the support
matrix, updating, uninstall. Everything else moved to docs/ (nested snapshots, how it
works, recovery, CLI, releasing).

A test enforces it: every internal link resolves, Install stays near the top, and the
README does not grow back. Moving Markdown breaks cross-references -- it broke eight
of them here, including one in a recovery doc, where the person following the link is
by definition already having a bad day.
2026-07-13 18:34:44 +00:00

1.7 KiB

Creating a task from the CLI

Part of truenas-truecloud-patch.

Creating a task via CLI

If the UI still shows only Storj after refreshing (e.g. the JS bundle pattern changed in a new TrueNAS version), create tasks directly. Run this on the TrueNAS host — it talks to the local middleware via midclt, so it needs no host address or API key:

# Replace /mnt/tank/truenas-truecloud-patch with your clone path

# List your cloud credentials to find the right ID
python3 /mnt/tank/truenas-truecloud-patch/patch/create_task.py list-credentials

# Create a task with a B2 credential (id=3).
# The restic repo password is read from stdin, so it never lands in your shell
# history — nor in any process's argv, where `ps` would expose it.
printf '%s' 'restic-repo-password' | \
python3 /mnt/tank/truenas-truecloud-patch/patch/create_task.py create \
    --name "tank-to-b2" \
    --path /mnt/tank/data \
    --credential 3 \
    --bucket my-bucket \
    --folder backups/tank \
    --password-stdin \
    --cache-path /mnt/tank/.restic-cache \
    --keep-last 14

Omit --password-stdin and you'll be prompted for the password instead. --password <secret> still works but warns: that password is the encryption key for the whole repository, and a CLI argument persists in your shell history forever.

Always pass --cache-path. Without it TrueNAS runs restic with --no-cache, which re-fetches all repo metadata from the provider every run — glacially slow on large repos. Point it at a writable dir on a pool with free space.

Versions ≤ 0.1.0 used the /api/v2.0 REST API with --host/--api-key; those flags are now accepted-but-ignored (REST is removed in TrueNAS 26.04).