content:en_us:dev_framework_tutorials_performing_a_webconfig_restart_on_install

Tutorials Performing a Webconfig Restart on Install

In some circumstances, it may be necessary to restart webconfig after installing an app, notably for:

  • Loading PHP modules (e.g. webconfig-php-mysql)
  • Adding aliases

Since the installation process is started via webconfig's Marketplace, the act of restarting webconfig will stop the install process. Chicken, meet egg!

Solution: Asynchronous Restart

In order to get around the webconfig restart issue, a ClearOS event (using clearsync) monitors two directories for changes:

  • /usr/clearos/sandbox/etc/php.d
  • /usr/clearos/sandbox/etc/httpd/conf.d

For example, when the MySQL module for PHP (webconfig-php-mysql) is installed, the /usr/clearos/sandbox/etc/php.d/mysql.ini is added. The ClearOS event detects the change and then waits for the install to complete before it restarts webconfig.

search?q=clearos%2C%20clearos%20content%2C%20dev%2C%20framework%2C%20maintainer_dloper%2C%20maintainerreview_x%2C%20keywordfix&btnI=lucky

content/en_us/dev_framework_tutorials_performing_a_webconfig_restart_on_install.txt · Last modified: 2015/03/02 23:02 by dloper