fix: drop :80 port suffix from service proxy URL for RBAC compatibility

When the proxy URL includes `:80`, Kubernetes checks the RBAC
resourceName as `polaris-dashboard:80` which doesn't match the
Role's resourceNames `["polaris-dashboard"]`. Dropping the port
suffix uses the service's default port and matches the RBAC correctly.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-02-07 19:10:55 -05:00
parent 1421a159dd
commit 39d85a3596
3 changed files with 6 additions and 6 deletions
+2 -2
View File
@@ -146,7 +146,7 @@ export function setRefreshInterval(seconds: number): void {
// --- Polaris dashboard proxy URL ---
export const POLARIS_DASHBOARD_PROXY =
'/api/v1/namespaces/polaris/services/polaris-dashboard:80/proxy/';
'/api/v1/namespaces/polaris/services/polaris-dashboard/proxy/';
// --- Score computation ---
@@ -158,7 +158,7 @@ export function computeScore(counts: ResultCounts): number {
// --- Data fetching hook ---
const POLARIS_API_PATH =
'/api/v1/namespaces/polaris/services/polaris-dashboard:80/proxy/results.json';
'/api/v1/namespaces/polaris/services/polaris-dashboard/proxy/results.json';
interface PolarisDataState {
data: AuditData | null;