A standalone container for web_server, shaped like job-tracker: serves /usaco/ with solved problems public and solving/skipped plus edits (status, link, notes) for the site admin. Git is the only store: the server clones adamf/usaco from Gitea, pulls on the push webhook, and commits edits back. CI builds the image only when site/ changes. Co-Authored-By: Claude Opus 5.5 <[email protected]>
14 lines
534 B
JavaScript
14 lines
534 B
JavaScript
/**
|
|
* What to do when an admin action is refused.
|
|
*
|
|
* The site has no login of its own: it borrows the main site's session
|
|
* (internal/auth on the server), as the job tracker does. By the time a
|
|
* request is refused the server has already tried the site's refresh token,
|
|
* so the only way back is the site's login page, which returns here after.
|
|
*/
|
|
|
|
export function goToLogin() {
|
|
const here = window.location.pathname + window.location.search;
|
|
window.location.assign(`/admin/login?redirect=${encodeURIComponent(here)}`);
|
|
}
|