canasta export
canasta > export
canasta export
Export the database of a wiki in a Canasta instance
Synopsis
Export a wiki's database as a SQL dump file. The instance must be running. By default the dump is saved to <wikiID>.sql in the current directory, or, for an instance on a remote host, in the home directory of the SSH user there. Use a .gz extension on the output path to get a gzip-compressed dump.
Each extra database the wiki declares (see canasta backup databases) is exported to its own file beside the main one, named <stem>.<database>.sql (or .sql.gz), where <stem> is the output path without its .sql/.sql.gz extension. For example, canasta export -w main with a declared main_cargo writes main.sql and main.main_cargo.sql. canasta import reads them from the same place.
canasta export [flags]
Examples
canasta export -w main
canasta export -w main -f backup.sql.gz
Flags
| Flag | Shorthand | Description | Default | Required | Orchestrator |
|---|---|---|---|---|---|
--wiki |
-w |
ID of the wiki to export | ✓ | Both | |
--file |
-f |
Output file path on the instance's host (default: <wikiID>.sql, use .gz for compression). For an instance on a remote host, an absolute path or one starting with a quoted '~' (for example '~/x') | Both | ||
--id |
-i |
Canasta instance ID | * | Both |
* Defaults to the Canasta instance matching the current directory, if any.
Global flags
| Flag | Shorthand | Description | Default | Required | Orchestrator |
|---|---|---|---|---|---|
--help |
-h |
Show help message and exit | Both | ||
--verbose |
-v |
Enable verbose output | Both |