Commit Graph
16 Commits
Author SHA1 Message Date
Felix FaerberandClaude Opus 5 c0e7b0f8a5 declare the VITE args in the stage that builds
Docker / build (push) Successful in 19s
The build args were only in development-dependencies-env, which runs npm ci.
npm run build happens in build-env, and args do not cross stages -- so Vite has
never seen VITE_API_URL, VITE_GOOGLE_CLIENT_ID or VITE_COMMIT_SHA in any image
this Dockerfile has produced.

It went unnoticed because app/routes/*.tsx fall back to
https://api.t4t-gateway.com, which is correct for the VPS image and silently
wrong everywhere else: the homelab instance deployed today served a UI that
called production, exactly what building it separately was meant to prevent.
Verified from the served bundle -- assets/signup-*.js carried the VPS URL.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CYFnHida4AdiNDek2pzgXx
2026-09-15 13:03:27 +03:00
Felix FaerberandClaude Opus 5 70786f73ab push with a write:package token, not the Actions token
Docker / build (push) Failing after 17s
Second build failed the same way: docker login to this instance's registry
returns "unauthorized" for the automatic Actions token, and declaring
permissions: packages: write did not change it -- Gitea's task token is accepted
by the API but not by the package registry.

So the push uses REGISTRY_TOKEN, an org secret holding a personal access token
scoped to write:package and nothing else. The step fails with that sentence in
the log rather than another bare "unauthorized", because the difference
between a missing secret and a rejected credential is not visible from the
error docker prints.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CYFnHida4AdiNDek2pzgXx
2026-09-15 12:38:14 +03:00
Felix FaerberandClaude Opus 5 f2f3e4e3f9 declare packages: write so the registry login works
Docker / build (push) Failing after 17s
The first build pushed nothing: `docker login git.ffaerber.duckdns.org` came
back "unauthorized". Gitea scopes the automatic Actions token from the job's
permissions block, and without one it has no package write -- so the build
succeeded and the push failed on auth, which reads like a credential problem
rather than a missing declaration.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CYFnHida4AdiNDek2pzgXx
2026-09-15 12:36:51 +03:00
ffaerber 7534f34cfc Merge pull request 'Build on Gitea, push to the Gitea registry' (#1) from ci/gitea-actions into main
Docker / build (push) Failing after 17s
2026-09-15 11:33:20 +02:00
Felix Faerber 67b00b8848 build on Gitea, against the homelab API
Docker / build (pull_request) Successful in 23s
Same move as the gateway repo -- build on the homelab runner, push to this
Gitea's registry, no deploy step -- with one difference that matters more here
than anywhere else.

Vite inlines import.meta.env at BUILD time. VITE_API_URL is therefore baked into
the bundle, and the GitHub build bakes https://api.t4t-gateway.com. Running that
image on the homelab would put a UI at t4tgw.ffaerber.duckdns.org that talks to
the VPS: a test signup would create a real account on production, and the two
instances would look identical while being the same instance. This build bakes
the homelab API, which is what makes running them side by side mean anything.

The app also falls back to the production URL when the variable is missing
(app/routes/*.tsx), so an unset build arg fails the same way silently. It is set
explicitly in the workflow env rather than left to a default.

.github/workflows is removed from this copy so Gitea does not try to run the
GitHub one; the GitHub repository keeps its own.
2026-09-15 12:30:27 +03:00
Felix FaerberandClaude 793fa899bf Add chat history sidebar with restore across reloads (#1)
Chat messages previously lived only in React state and vanished on
navigation or refresh. Persist each conversation as a session in
localStorage and add a sidebar to switch between, restore, or delete
past chats, matching the pattern of the account page's client-side
persistence.


Claude-Session: https://claude.ai/code/session_012RrMZ8Y9BhuMkKNcw2bakZ

Co-authored-by: Claude <noreply@anthropic.com>
2026-08-19 00:20:30 +03:00
Felix FaerberandClaude Opus 4.7 83760c4a9b add shared navbar on /account, /chat, /bee
Three-link nav (Chat / Account / Bee) with active-route highlighting,
plus a t4t Gateway home link on the left. Replaces the bespoke header
on the chat page; account and bee gain the same top-of-page nav.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-28 09:29:20 +03:00
Felix FaerberandClaude Opus 4.7 86e0ab356a account: add Recent jobs table
Fetch /v1/jobs alongside the existing account data and render the
last 25 in a table — model, status pill, provider, tokens, cost,
timestamp. Mirrors the homelab gateway's /wallet job list.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 15:46:28 +03:00
Felix FaerberandClaude Opus 4.7 c538822e4f add /bee page — read-only bee node stats from /bee/stats
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 15:12:30 +03:00
Felix FaerberandClaude Opus 4.7 e8081baec1 pull :main before stack deploy so swarm uses the freshly built image
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 14:57:07 +03:00
Felix Faerber 291bdeffc0 retrigger build 2026-05-27 14:15:15 +03:00
Felix FaerberandClaude Opus 4.7 2025314836 add /chat route — in-app chat against the gateway
Uses the user's JWT against /v1/models + /v1/chat/completions (the
gateway's /v1 routes already accept JWT — no API key needed for the
in-app chat path; API keys remain for external SDK usage).

Single-turn UX for now, no streaming. Model picker reads /v1/models.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 13:23:09 +03:00
Felix FaerberandClaude Opus 4.7 97d80c396d add /account dashboard
- xBZZ balance prominently
- API keys: create / list / revoke; new key surfaced once in a copy dialog
- Recent ledger entries (welcome credit, job charges, top-ups)
- Auth: JWT from localStorage; 401 clears JWT + redirects to /login
- Sign-out button

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 13:18:05 +03:00
Felix FaerberandClaude Opus 4.7 0fdfed9909 add /login route
POSTs email + password to /auth/email/login, stores JWT, redirects
to /account (route to be added).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 12:43:59 +03:00
Felix FaerberandClaude Opus 4.7 0a82519f99 grant packages:write to docker-image workflow
GITHUB_TOKEN defaults to read-only; without packages:write the push
to ghcr.io/token-for-token/hosted-gateway-frontend gets "installation
not allowed to Create organization package".

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 12:38:36 +03:00
Felix FaerberandClaude Opus 4.7 974250b357 first commit
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 12:22:05 +03:00