Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Commands

CommandDoes
moekura serveruns the web server, plus job workers unless jobs.run_in_serve = false; migrates first unless database.auto_migrate = false
moekura workerruns job workers only
moekura tagger [--check]runs the tagger (a build with the tagger feature); --check only loads ONNX Runtime
moekura migrateapplies pending migrations and exits
moekura check-configvalidates the configuration and prints it, secrets redacted
moekura openapiprints the API’s OpenAPI description
moekura admin create-user NAME [--role ROLE] [--email E]creates an account; asks for the password, or reads one line from standard input
moekura admin create-user NAME --bot [--role ROLE]creates a bot, which has no password and uses API keys only
moekura admin set-role NAME ROLEchanges someone’s role
moekura admin set-owner NAMEmakes someone the site’s owner, who outranks every role, in place of the current one
moekura admin set-bot NAME [--off]makes an account a bot, ending its sessions and revoking its feed token, or with --off a person’s again
moekura admin lift-network-ban ADDRESS_OR_RANGElifts the network bans covering an address, or overlapping a range, such as one that locks staff out
moekura admin create-invite [--uses N] [--expires-days D]makes an invite code, shown once
moekura admin create-api-key USER --name N [--permission P]… [--expires-days D]makes an API key for someone, such as a bot, and prints it once; each --permission (view_posts, upload, …) limits the key to the ones given, and without any it can do everything the user can
moekura admin api-keys USERlists someone’s API keys: id, name, first characters, what each may do, and when it was made, last used and expires
moekura admin revoke-api-key USER IDrevokes one of them, by its id from api-keys
moekura admin settingsshows the site settings
moekura admin settings set KEY VALUEchanges one; VALUE is JSON, or else a plain string
moekura admin regenerate-media (--all | IDS…)remakes thumbnails and samples, and rereads the files’ metadata
moekura admin recount-tagsrecomputes every tag’s post count
moekura admin tag-backlog [--all] [--limit N]queues posts the tagger hasn’t seen (or, with --all, every post)
moekura admin send-test-mail ADDRESSsends a test message through the [mail] settings
moekura admin import DIR --uploader NAME …imports a folder of files; see Bulk import
moekura admin export DIR [--tags SEARCH] [--include-deleted]writes posts’ files and sidecars to a folder; see Exporting
moekura admin seed --posts N [--tags T] [--seed S]fills a test database with synthetic posts for load testing; see Scaling
moekura admin bench [--check] [--explain NAME]times a suite of searches against the database
moekura admin bench-http [--url URL] [--concurrency N] [--check-ms MS]times pages and API responses from a running server; see Scaling

Every command takes --config PATH. Role and setting changes, and lifted network bans, made here appear in the moderation log.