Upload via GUI (338 Dateien)
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
/**
|
||||
* Kleiner, öffentlicher Erreichbarkeitstest für die DeskHub-API.
|
||||
* Gibt keine internen Details oder Zugangsdaten zurück.
|
||||
*/
|
||||
require_once __DIR__ . '/../../../includes/bootstrap.php';
|
||||
|
||||
header('Content-Type: application/json; charset=utf-8');
|
||||
header('Cache-Control: no-store');
|
||||
|
||||
try {
|
||||
get_db()->query('SELECT 1');
|
||||
echo json_encode(['status' => 'ok'], JSON_UNESCAPED_UNICODE);
|
||||
} catch (Throwable $e) {
|
||||
http_response_code(503);
|
||||
echo json_encode(['status' => 'unavailable'], JSON_UNESCAPED_UNICODE);
|
||||
}
|
||||
Reference in New Issue
Block a user