ENH Update config to reflect changes in CLI interaction (#112)

This commit is contained in:
Guy Sartorelli 2024-09-26 17:28:48 +12:00 committed by GitHub
parent 9cd1ae9a3b
commit 51b9b649c7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 8 additions and 76 deletions

View File

@ -1,70 +0,0 @@
<?php
//
//use SilverStripe\EnvironmentCheck\EnvironmentCheckSuite;
//
//// These power dev/health, which can be used by load balancers and other such systems
//EnvironmentCheckSuite::register('health', 'DatabaseCheck');
//
//// These power dev/check, which is used for diagnostics and for deployment
//EnvironmentCheckSuite::register('check', 'DatabaseCheck("Member")', "Is the database accessible?");
//EnvironmentCheckSuite::register('check', 'URLCheck("")', "Is the homepage accessible?");
//
//EnvironmentCheckSuite::register(
// 'check',
// 'HasFunctionCheck("curl_init")',
// "Does PHP have CURL support?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'HasFunctionCheck("imagecreatetruecolor")',
// "Does PHP have GD2 support?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'HasFunctionCheck("xml_set_object")',
// "Does PHP have XML support?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'HasFunctionCheck("token_get_all")',
// "Does PHP have tokenizer support?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'HasFunctionCheck("iconv")',
// "Does PHP have iconv support?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'HasFunctionCheck("hash")',
// "Does PHP have hash support?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'HasFunctionCheck("session_start")',
// "Does PHP have session support?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'HasClassCheck("DOMDocument")',
// "Does PHP have DOMDocument support?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'FileWriteableCheck("assets")',
// "Is assets/ writeable?"
//);
//
//EnvironmentCheckSuite::register(
// 'check',
// 'FileWriteableCheck("' . TEMP_FOLDER . '")',
// "Is the temp folder writeable?"
//);

View File

@ -4,14 +4,12 @@ Name: environmentcheckroutes
SilverStripe\Control\Director: SilverStripe\Control\Director:
rules: rules:
'health/check': 'Silverstripe\EnvironmentCheck\Controllers\DevHealthController' 'health/check': 'Silverstripe\EnvironmentCheck\Controllers\DevHealthController'
'dev/check/$Suite': 'Silverstripe\EnvironmentCheck\Controllers\DevCheckController'
SilverStripe\Dev\DevelopmentAdmin: SilverStripe\Dev\DevelopmentAdmin:
registered_controllers: controllers:
check: check:
controller: Silverstripe\EnvironmentCheck\Controllers\DevCheckController class: Silverstripe\EnvironmentCheck\Controllers\DevCheckController
links: description: 'Run registered environment checks and display their status'
check: 'Run registered environment checks and display their status'
--- ---
Name: environmentcheckroutes-dev_urls-confirmation-exceptions Name: environmentcheckroutes-dev_urls-confirmation-exceptions

View File

@ -14,6 +14,10 @@ use SilverStripe\EnvironmentCheck\EnvironmentChecker;
*/ */
class DevCheckController extends Controller class DevCheckController extends Controller
{ {
private static $url_handlers = [
'$Suite' => 'index',
];
/** /**
* @var array * @var array
*/ */