Command Line Interface

Some administrative tasks can also or exclusively be executed by console. This guide lists the most important console commands used to administer HumHub. All available console commands can be displayed by running php yii within the protected directory of your HumHub installation.

All of the following commands can be executed withine the @humhub/protected directory.

Example

cd protected
php yii cache/flush-all

Commands

cache

CommandDescription
cache/flushAllows you to flush cache
cache/flush-allCombines and compresses the asset files according to the given configuration
cache/flush-schemaClears DB schema cache for a given connection component
cache/index (default)Lists the caches that can be flushed

cron

CommandDescription
cron/dailyForce run of the daily cron jobs
cron/hourlyForce run of the hourly cron jobs
cron/runRuns the cron jobs

help

Provides help information about console commands.

CommandDescription
help/index (default) Displays available commands or the detailed information
help/list List all available controllers and actions in machine readable format
help/list-action-optionsList all available options for the $action in machine readable format
help/usageDisplays usage information for $action

integrity

Performs data integrity checks.

CommandDescription
integrity/runStarts integrity checker

ldap

Console tools for manage Ldap

CommandDescription
ldap/list (default)Lists configured LDAP auth clients
ldap/list-usersLists all users found in the LDAP server
ldap/mapping-clearClears the authclient_id entries in the user table.
ldap/mapping-rebuildRebuilds the authclient_id and auth_mode mappings in the user table
ldap/statusReturns status information
ldap/syncSynchronizes all ldap users (if autoRefresh is enabled)

migrate

Manages application migrations.

CommandDescription
migrate/up (default)Upgrades the application by applying new migrations
migrate/historyDisplays the migration history

Include module migrations:

php yii migrate/up --includeModuleMigrations=1

module

HumHub Module Management

CommandDescription
module/disableDisables an enabled module
module/enableEnables an installed module
module/installInstalls a given module
module/listLists all installed and enabled modules
module/list-onlineLists all online available modules
module/removeUninstalls a given module
module/updateUpdates a given module
module/update-allUpdates all modules to the latest available version

queue

HumHub Queue Management

CommandDescription
queue/clearClears the queue
queue/execExecutes a job
queue/info (default)Info about queue status
queue/listenListens db-queue and runs new jobs
queue/removeRemoves a job by id.
queue/runRuns all jobs from db-queue

search

HumHub Search Tools

CommandDescription
search/findSearch the index
search/optimizeOptimizes the search index
search/queue-rebuildQueue search index rebuild
search/rebuildRebuilds the search index

settings

Provides CLI access to database settings.

CommandDescription
settings/deleteDeletes a stored setting
settings/listLists all stored settings
settings/list-moduleLists stored settings by given module id
settings/setAdds or updates a stored setting

space

Console tools for manage spaces

CommandDescription
space/assign-all-membersAssign all members to a given space

test

Provides some console tests

CommandDescription
test/emailSends a test e-mail to the given e-mail address

theme

Theme CLI Tools

CommandDescription
theme/info (default)Shows all available and active themes
theme/switch (default)Switches the current theme