Appearance
CLI Command Reference
General
version
Show installed Zou version.
bash
zou versionDatabase Management
init-db
Create database tables (database must already exist).
bash
zou init-dbis-db-ready
Check if database is initialized.
bash
zou is-db-readymigrate-db
Generate migration files to describe a new revision of the database schema (development only).
bash
zou migrate-db --message "add new column"Options:
--message: Migration description (default:"").
downgrade-db
Downgrade database to a previous schema revision (development only).
bash
zou downgrade-db --revision -1Options:
--revision: Target revision (default:"-1").
upgrade-db
Upgrade database schema.
bash
zou upgrade-dbOptions:
--no-telemetry: Disable anonymized statistics (default:False).
stamp-db
Set the database schema revision without running migrations.
bash
zou stamp-db --revision abc123Options:
--revision: Target revision hash (default: current).
clear-db
Drop all tables from the database.
bash
zou clear-dbreset-db
Drop all tables, then recreate them.
bash
zou reset-dbreset-migrations
Reset migration state to base revision.
bash
zou reset-migrationsUser & Authentication
create-admin
Create an admin user or upgrade an existing user to admin.
bash
zou create-admin admin@example.com --password mysecretpasswordArguments:
email: User email address (required).
Options:
--password: Admin password.
change-password
Change the password of a given user.
bash
zou change-password user@example.com --password newpasswordArguments:
email: User email address (required).
Options:
--password: New password (required).
set-person-as-active
Activate or deactivate a user account.
bash
zou set-person-as-active user@example.com
zou set-person-as-active user@example.com --unactiveArguments:
email: User email address (required).
Options:
--unactive: Deactivate instead of activate (default:False).
disable-two-factor-authentication
Disable two-factor authentication for a given user.
bash
zou disable-two-factor-authentication user@example.comArguments:
email-or-desktop-login: User email or desktop login (required).
clean-auth-tokens
Remove revoked and expired authentication tokens.
bash
zou clean-auth-tokensclear-all-auth-tokens
Remove all authentication tokens.
bash
zou clear-all-auth-tokenssync-with-ldap-server
For each user account in your LDAP server, create a corresponding Kitsu user.
bash
zou sync-with-ldap-servercreate-bot
Create a bot account for API automation.
bash
zou create-bot --email bot@example.com --name "Pipeline Bot" --role userOptions:
--email: Bot email address (required).--name: Bot display name (required).--expiration-date: Token expiration date inYYYY-MM-DDformat.--role: Bot role (default:"user").
Data Initialization & Maintenance
init-data
Generate the minimal data set required to run Kitsu (task statuses, types, etc.).
bash
zou init-dataremove-old-data
Remove old events, notifications, and login logs.
bash
zou remove-old-data --days 90Options:
--days: Remove data older than this many days (default:90).
clean-tasks-data
Reset task model data (retake count, WIP start date, and end date).
bash
zou clean-tasks-data --project-id a24a6ea4-ce75-4665-a070-57453082c25Options:
--project-id: Limit to a specific project. If omitted, applies to all projects.
reset-search-index
Reset the full-text search index.
bash
zou reset-search-indexsearch-asset
Search for assets in the index.
bash
zou search-asset --query "main character"Options:
--query: Search query string (default:"").
Instance Synchronization
Requires SYNC_LOGIN and SYNC_PASSWORD environment variables.
sync-full
Retrieve all data from a source instance.
bash
zou sync-full --source https://source-kitsu.com/api --project "My Project"Options:
--source: Source instance API URL (default:"http://localhost:5000").--project: Sync only a specific project by name.--no-projects: Skip project data (default:False).--with-events: Include event history (default:False).--only-projects: Sync project data only, skip everything else (default:False).
sync-full-files
Retrieve all files from a source instance.
bash
zou sync-full-files --source https://source-kitsu.com/api --multithreadedOptions:
--source: Source instance API URL (default:"http://localhost:5000").--project: Sync files for a specific project only.--multithreaded: Enable parallel downloads (default:False).--number-workers: Number of parallel workers (default:30).--number-attemps: Number of retry attempts per file (default:3).--force-resync: Re-download files that already exist locally (default:False).
sync-changes
Run a daemon that imports data for any change happening on the source instance.
bash
zou sync-changes --event-source https://source-kitsu.com --source https://source-kitsu.com/apiOptions:
--event-source: Source instance event stream URL (default:"http://localhost:8080").--source: Source instance API URL (default:"http://localhost:8080/api").--logs-directory: Directory for sync logs.
sync-file-changes
Run a daemon that downloads files for any change happening on the source instance.
bash
zou sync-file-changes --event-source https://source-kitsu.com --source https://source-kitsu.com/apiOptions:
--event-source: Source instance event stream URL (default:"http://localhost:8080").--source: Source instance API URL (default:"http://localhost:8080/api").--logs-directory: Directory for sync logs.
sync-last-events
Retrieve recent events from a source instance and import related data.
bash
zou sync-last-events --source https://source-kitsu.com/api --minutes 30Options:
--source: Source instance API URL (default:"http://localhost:8080/api").--minutes: Sync events from the last N minutes (default:0).--page-size: Number of events per page (default:300).
sync-last-files
Retrieve recent preview files and thumbnails from a source instance.
bash
zou sync-last-files --source https://source-kitsu.com/api --minutes 60Options:
--source: Source instance API URL (default:"http://localhost:8080/api").--minutes: Sync files from the last N minutes (default:20).--page-size: Number of files per page (default:50).
Storage & Backups
download-storage-files
Download all files from a Swift object storage and store them locally.
bash
zou download-storage-filesdump-database
Dump the database. Optionally upload the dump to configured object storage.
bash
zou dump-database --storeOptions:
--store: Upload the dump to remote object storage (default:False).
upload-files-to-cloud-storage
Upload preview files to configured object storage.
bash
zou upload-files-to-cloud-storage --days 7Options:
--days: Only upload files from the last N days. If omitted, uploads all files.
Preview & Media Maintenance
generate-preview-extra
Generate tiles, thumbnails, and metadata for previews.
bash
zou generate-preview-extra --project "My Project" --with-tiles --with-thumbnailsOptions:
--project: Limit to a specific project by name.--entity-id: Limit to a specific entity by UUID.--episode: Limit to specific episodes (can be repeated).--only-shots: Process only shot previews (default:False).--only-assets: Process only asset previews (default:False).--with-tiles: Generate tile images (default:False).--with-metadata: Generate metadata (default:False).--with-thumbnails: Generate thumbnails (default:False).--force-regenerate-tiles: Regenerate tiles even if they already exist (default:False).
reset-movie-files-metadata
Store height and width metadata for all movie previews in the database.
bash
zou reset-movie-files-metadatareset-picture-files-metadata
Store height and width metadata for all picture previews in the database.
bash
zou reset-picture-files-metadatarenormalize-movie-preview-files
Renormalize movie preview files.
bash
zou renormalize-movie-preview-files --project-id a24a6ea4-ce75-4665-a070-57453082c25Options:
--preview-file-id: Renormalize a single preview file by UUID.--project-id: Limit to a specific project by UUID.--all-broken: Renormalize all broken preview files (default:False).--all-processing: Renormalize all files stuck in processing state (default:False).--days: Renormalize files from the last N days.--hours: Renormalize files from the last N hours.--minutes: Renormalize files from the last N minutes.
reset-breakdown-data
Reset breakdown statistics for all open projects.
bash
zou reset-breakdown-dataCache
clear-memory-cache
Clear the Redis memory cache.
bash
zou clear-memory-cachePlugin Management
install-plugin
Install a plugin from a local folder, .zip archive, or git repository URL.
bash
zou install-plugin --path /path/to/plugin
zou install-plugin --path ./dist/my-plugin.zip
zou install-plugin --path https://github.com/cgwire/kitsu-tickets.gitOptions:
--path: Path to the plugin folder,.ziparchive, or git URL (required).--force: Overwrite if already installed (default:False).
Note: Restart the Zou server after installing a plugin.
uninstall-plugin
Uninstall a previously installed plugin.
bash
zou uninstall-plugin --id my_pluginOptions:
--id: Plugin ID to uninstall (required).
WARNING
This removes plugin files and unregisters its migrations. Database tables created by the plugin are not dropped automatically — remove them manually if needed.
create-plugin-skeleton
Generate the basic structure of a new plugin.
bash
zou create-plugin-skeleton --path ./plugins --id my_pluginOptions:
--path: Directory where the plugin will be created (required).--id: Unique plugin ID (required).--name: Human-readable plugin name (default:"MyPlugin").--description: Short description (default:"My plugin description.").--version: Semantic version string (default:"0.1.0").--maintainer: Contact info (default:"Author <author@author.com>").--website: Plugin/project website (default:"mywebsite.com").--license: License identifier (default:"GPL-3.0-only").--icon: Lucide icon name.--force: Overwrite if directory exists (default:False).
create-plugin-package
Package a plugin folder into a zip file, ready for installation.
bash
zou create-plugin-package --path ./plugins/my_plugin --output-path ./distOptions:
--path: Plugin source folder (required).--output-path: Destination folder for the.zip(required).--force: Overwrite existing archive if present (default:False).
list-plugins
List all currently installed plugins.
bash
zou list-plugins
zou list-plugins --format json --verboseOptions:
--format: Output format,tableorjson(default:"table").--verbose: Show more metadata (default:False).--filter-field: Filter by a specific field (plugin_id,name,maintainer,license).--filter-value: Value to search in the selected field.
migrate-plugin-db
Generate and apply database migrations for a plugin.
bash
zou migrate-plugin-db --path ./plugins/my_pluginOptions:
--path: Path to the plugin folder (required).--message: Optional migration message (default:"").
