function hostmaster_task_init in Hostmaster (Aegir) 5.x
Form that confirms that cron is running, and that the platform has been successfuly verified
This page is essentially one huge page of contextual help, to ensure that everything is up and running.
File
- ./
hostmaster.forms.inc, line 200
Code
function hostmaster_task_init() {
drupal_set_title(st('Initialize the hosting system'));
// @ TODO: make this coherent, and add error reporting about what went wrong, and how it needs to be fixed.
$form = array();
$form['intro']['#value'] = t('<p>The hosting framework provides the user interface used to administer your sites.
All components of the managed sites from the database and web servers, to the packages installed
on them, to the sites themselves are represented by the hosting framework as nodes.
This step is going to ensure that it is correctly initialized.</p>');
$options = array(
'#configuration' => HOSTING_HELP_COLLAPSIBLE,
);
if (!variable_get('hosting_dispatch_enabled', FALSE)) {
$options['#status'] = HOSTING_STATUS_WARNING;
$options['#message'] = t('Please follow the configuration help below to initialize the system.');
}
elseif (!variable_get('hosting_dispatch_last_run', false)) {
$options['#status'] = HOSTING_STATUS_ERROR;
$options['#message'] = t('The dispatch process has not been run. Please follow the instructions below.');
}
else {
$options['#status'] = HOSTING_STATUS_SUCCESS;
$options['#message'] = t('The dispatch process has been succesfully executed');
}
$form['cron'] = hostmaster_requirement_help('hosting_setup', $options);
return hostmaster_form($form);
}