CLI:Canasta import
From canasta
canasta > import
canasta import
Import a database into an existing wiki
Synopsis
Import a database dump into an existing wiki, replacing its current database. The instance must be running. Supported formats are .sql and .sql.gz files.
To create a new wiki from a database dump, use the --database flag with 'canasta create' or 'canasta add' instead.
canasta import [flags]
Examples
# Import a SQL dump into a wiki canasta import -i myinstance -w main -d /path/to/dump.sql # Import a gzipped dump and replace the wiki's Settings.php canasta import -i myinstance -w main -d /path/to/dump.sql.gz -l /path/to/Settings.php
Flags
| Flag | Shorthand | Description | Default | Required |
|---|---|---|---|---|
--database |
-d |
Path to SQL dump file (.sql or .sql.gz) | ✓ | |
--help |
-h |
help for import | ||
--id |
-i |
Canasta instance ID | instance associated with current directory | |
--wiki |
-w |
ID of the wiki to import into | ✓ | |
--wiki-settings |
-l |
Path to per-wiki Settings.php to replace the existing one | ||
--verbose |
-v |
Verbose output |