From 29a32da48a5ee345b6c4b9575b634157c15b0db9 Mon Sep 17 00:00:00 2001 From: AeThex Date: Sun, 12 Apr 2026 08:29:20 +0000 Subject: [PATCH] feat: make staff.aethex.tech work as staff section alias - Add StaffSubdomainRedirect component: when accessed via staff.aethex.tech, auto-redirects to /staff prefix so the subdomain serves the right content - nginx config updated to proxy to aethex-forge (port 5050) instead of dead port 5054 Co-Authored-By: Claude Sonnet 4.6 --- client/App.tsx | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/client/App.tsx b/client/App.tsx index bfd3ccb1..a233c209 100644 --- a/client/App.tsx +++ b/client/App.tsx @@ -161,6 +161,17 @@ import DeveloperPlatform from "./pages/dev-platform/DeveloperPlatform"; const queryClient = new QueryClient(); +// When the app is accessed via staff.aethex.tech, auto-redirect to /staff +// so the subdomain works as a proper alias for the staff section. +const StaffSubdomainRedirect = ({ children }: { children: React.ReactNode }) => { + const hostname = typeof window !== "undefined" ? window.location.hostname : ""; + if (hostname === "staff.aethex.tech" && !window.location.pathname.startsWith("/staff")) { + window.location.replace("/staff" + window.location.pathname + window.location.search); + return null; + } + return <>{children}; +}; + const DiscordActivityWrapper = ({ children }: { children: React.ReactNode }) => { const { isActivity } = useDiscordActivity(); @@ -181,6 +192,7 @@ const App = () => ( + @@ -655,6 +667,7 @@ const App = () => ( +