Files
desktop/public/index.php
Lars Gebhardt-Kusche 823c5d197d
All checks were successful
Deploy / deploy-staging (push) Successful in 47s
Deploy / deploy-production (push) Has been skipped
update
2026-06-15 02:38:41 +02:00

32 lines
667 B
PHP

<?php
declare(strict_types=1);
require_once dirname(__DIR__) . '/src/App/bootstrap.php';
use App\App;
use App\ConfigLoader;
use App\KeycloakAuth;
session_start();
$projectRoot = dirname(__DIR__);
$keycloakConfig = ConfigLoader::load($projectRoot, 'keycloak');
$auth = new KeycloakAuth($keycloakConfig);
if (!$auth->shouldShowDesktop()) {
if ($auth->isConfigured()) {
header('Location: /auth/keycloak', true, 302);
exit;
}
http_response_code(503);
echo 'Keycloak ist nicht konfiguriert.';
exit;
}
$app = new App($projectRoot);
$desktopPayload = $app->desktopPayload();
require $projectRoot . '/partials/desktop/shell.php';