Class humhub\modules\installer\commands\InstallController

Inheritancehumhub\modules\installer\commands\InstallController » yii\console\Controller

Console Install

Example usage: php yii installer/write-db-config "$HUMHUB_DB_HOST" "$HUMHUB_DB_NAME" "$HUMHUB_DB_USER" "$HUMHUB_DB_PASSWORD" php yii installer/install-db php yii installer/write-site-config "$HUMHUB_NAME" "$HUMHUB_EMAIL" php yii installer/create-admin-account

Public Methods

Hide inherited methods

MethodDescriptionDefined By
actionAuto() Finished install without input. Useful for testing. humhub\modules\installer\commands\InstallController
actionCreateAdminAccount() Creates a new user account and adds it to the admin-group humhub\modules\installer\commands\InstallController
actionInstallDb() Checks configured db, flushes caches, runs migrations and sets installed state in config humhub\modules\installer\commands\InstallController
actionSetBaseUrl() Sets the base url humhub\modules\installer\commands\InstallController
actionWriteDbConfig() Tries to open a connection to given db. humhub\modules\installer\commands\InstallController
actionWriteSiteConfig() Writes essential site settings to config file and sets installed state humhub\modules\installer\commands\InstallController

Method Details

actionAuto() public method

Finished install without input. Useful for testing.

public void actionAuto ( )
actionCreateAdminAccount() public method

Creates a new user account and adds it to the admin-group

public void actionCreateAdminAccount ( $admin_user 'admin', $admin_email 'humhub@example.com', $admin_pass 'test' )
$admin_user
$admin_email
$admin_pass
actionInstallDb() public method

Checks configured db, flushes caches, runs migrations and sets installed state in config

public void actionInstallDb ( )
actionSetBaseUrl() public method

Sets the base url

public void actionSetBaseUrl ( $base_url )
$base_url
actionWriteDbConfig() public method

Tries to open a connection to given db.

On success: Writes given settings to config-file and reloads it. On failure: Throws exception

public void actionWriteDbConfig ( $db_host, $db_name, $db_user, $db_pass )
$db_host
$db_name
$db_user
$db_pass
actionWriteSiteConfig() public method

Writes essential site settings to config file and sets installed state

public void actionWriteSiteConfig ( $site_name 'HumHub', $site_email 'humhub@example.com' )
$site_name
$site_email