diff --git a/auto_install.php b/auto_install.php new file mode 100644 index 0000000000..ef30d1912a --- /dev/null +++ b/auto_install.php @@ -0,0 +1,164 @@ +config['php_path'])) { + check_php($app->config['php_path'], $checks); + } else { + die(" ERROR: The php_path is not set in the config. Please check the file .htconfig.php.\n"); + } + + echo " NOTICE: Not checking .htaccess/URL-Rewrite during CLI installation.\n"; + + return $checks; +} + +function run_database_check() +{ + global $db_host; + global $db_user; + global $db_pass; + global $db_data; + + $result = array( + 'title' => 'MySQL Connection', + 'required' => true, + 'status' => true, + 'help' => '', + ); + + if (!dba::connect($db_host, $db_user, $db_pass, $db_data, true)) { + $result['status'] = false; + $result['help'] = 'Failed, please check your MySQL settings and credentials.'; + } + + return $result; +}