v2.0.13 — oumta-dashboard via PHP proxy; quiet support poll

Dashboard now reachable across the internet: browser calls /api/dashboard/*
same-origin, PHP forwards to OUMTA_DASHBOARD_URL (configurable via env,
with docker-compose defaults pointing at host.docker.internal:8085).
Keeps the bearer token server-side and lets the dashboard live on a
private network.

Plumbing bits: polling indicator now green (no reason to look anxious
about a healthy poll loop), and the support plugin returns 200 pulled=0
when its relay isn't configured instead of flooding the network tab
with 502s on every background tick.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
tuandClaude Opus 4.7 committed 2026-04-19 13:37:06 +02:00
1 parent 7bce6a3a36
commit efd3f9d5ae
6 files changed
+92 -26

No files matched your search

+9 -1
View File
@@ -1,7 +1,7 @@
<?php
define('APP_NAME', 'hyprcrd');
define('APP_VERSION', '2.0.12');
define('APP_VERSION', '2.0.13');
// APP_DEBUG: gates verbose error responses (curl traces, upstream bodies).
// Off by default; enable via env for local troubleshooting only.
@@ -18,3 +18,11 @@ $host = $_SERVER['HTTP_HOST'] ?? 'localhost';
$scriptDir = dirname($_SERVER['SCRIPT_NAME']);
$basePath = ($scriptDir === '/' || $scriptDir === '\\') ? '' : $scriptDir;
define('BASE_URL', $protocol . '://' . $host . $basePath);
// Oumta dashboard upstream. The browser only talks to /api/dashboard/*
// same-origin; the PHP proxy below forwards to this URL. Override via env
// for remote deployments. Inside Docker on Linux, localhost points at the
// container itself — use http://host.docker.internal:8085 (needs
// extra_hosts) or a routable URL to reach a host-side dashboard.
define('OUMTA_DASHBOARD_URL', getenv('OUMTA_DASHBOARD_URL') ?: 'http://localhost:8085');
define('OUMTA_DASHBOARD_TOKEN', getenv('OUMTA_DASHBOARD_TOKEN') ?: '');