Base Configuration ¶
This guide describes the base configurations required to operate a HumHub environment.
Note: Before going to production, see also the Security Chapter
Depending on your hosting environment, you may want to specify a local or remote SMTP Server.
The mail-server settings can be configured under
Administration -> Mailing -> Server Settings.
By default, the PHP Mail Transport is used.
Perhaps, you should consider a dedicated SMTP service, like SendGrid, Postmark, Amazon SES or Mailgun.
CronJobs and Asynchronous Job Processing (v1.3+) ¶
CronJobs are used to execute scheduled tasks as for example sending summary emails or search index optimization and they need to be configured in your server environment.
The scheduled job-runner can be executed manually as follows:
> /usr/bin/php /path/to/humhub/protected/yii cron/run
Asynchronous Jobs are used to execute potentially long running tasks in the background and can either be:
- run by an extra CronJob (see below),
- or by a job-runner alternative.
Please see Asynchronous Tasks for more details about queuing and job processing options.
The asynchronous job-runner can also be executed manually as follows:
> /usr/bin/php /path/to/humhub/protected/yii queue/run
Note: If you're on a shared hosting environment, you may need to add the
--isolated=0option to the
/usr/bin/php /path/to/humhub/protected/yii queue/run --isolated=0
Example CronTab configuration:
These Cronjobs can be run together if you're not using any other job-runner (like Supervisor or Systemd):
* * * * * /usr/bin/php /path/to/humhub/protected/yii queue/run >/dev/null 2>&1 * * * * * /usr/bin/php /path/to/humhub/protected/yii cron/run >/dev/null 2>&1
Warning: These two cron jobs are only both required if there is no other worker configured. See Asynchronous Tasks for more details. Please also note that additional job-workers can be configured only in dedicated environments, not shared hostings.
In case you've configured a job-worker (like Supervisor or Systemd), only the main Cronjob should be running paralel to the job-runner, so:
* * * * * /usr/bin/php /path/to/humhub/protected/yii cron/run >/dev/null 2>&1
Note: Please see the Cron Job Section for more information about the configuration of cron jobs.
URL Rewriting (Optional) ¶
URL rewriting can be used in order to use pretty urls. When enabled your HumHub installation will make use of urls like
http://localhost/humhub/directory/directory instead of
.htaccess.dist file residing in your HumHub root folder to
.htaccess and modify the local configuration located at
protected/config/common.php as follow:
<?php return [ 'components' => [ 'urlManager' => [ 'showScriptName' => false, 'enablePrettyUrl' => true, ], ] ];
Further Configuration Options ¶
Please see the Custom Configuration Section for further information about other configuration possibilities.