cc initdb
Restore a database from a dump file.
Usage
cc initdb [name]Arguments
| Argument | Description |
|---|---|
name | Database name to restore into. If omitted, uses the active environment's database. |
How It Works
- Looks in your configured download directory for
.zipdump files - If multiple files are found, lets you choose one
- Extracts
dump.sqlfrom the zip - Creates the PostgreSQL database if it doesn't exist
- Restores the dump via
psql - Copies the filestore to
~/.local/share/Odoo/filestore/{db_name}if present - Runs cleanup SQL (removes mail servers, crons, etc.)
Configure Download Directory
cc configPick Downloads path from the settings picker and set it to the folder where you save dump files (e.g. ~/Downloads).
Dump Format
CC expects the standard Odoo backup format:
backup.zip
├── dump.sql
└── filestore/ (optional)