Feat/selfhost i18n domain global - #195
Open
safar2x wants to merge 3 commits into
Open
Conversation
- Add i18next + react-i18next, en/ar locale files, and a language preference menu so the app can run in Arabic or English. - Wire translated labels through the sidebar, keyword research page, create-project modal, project market fields, and settings page. - Add a HelpHint component for inline contextual help text. - alchemy.run.ts: bind the "selfhost" deploy stage to a custom domain (seo.safar2x.com) so it survives future deploy reconciliations instead of being torn down. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…n Overview
- Domain Overview's country picker gains a "Global (Top 10 Markets)"
option: since DataForSEO Labs has no worldwide-aggregate endpoint,
this sums/merges results across a fixed set of the largest search
markets (US, UK, India, Brazil, Germany, France, Canada, Australia,
Japan, Indonesia) instead of querying all ~94 supported countries,
keeping the cost/latency of a domain search bounded.
- Overview cards sum organic traffic/keywords across the top markets.
- The keywords and pages tables merge each market's results
(deduped by keyword/URL, keeping the highest-traffic instance),
re-sort locally, and paginate the merged set.
- Add a Refresh button next to the domain search box that deletes the
R2-cached entry for the exact current query (domain, location, page,
sort, filters) and re-fetches, bypassing the up-to-12h cache TTL.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Adds machineAccessToken (alchemy.access.ts) and wires it into the selfhost stage's deploy (alchemy.run.ts): provisions a Cloudflare Access Service Token and prints its Client ID/Secret on deploy, so a non-interactive client (e.g. an MCP client hitting /mcp) can authenticate with CF-Access-Client-Id/CF-Access-Client-Secret headers instead of the interactive IdP login the rest of the app requires. Deliberately does not attach the token to an Access application: the app's own JWT check (src/middleware/ensure-user/cloudflareAccess.ts) verifies the token's `aud` against POLICY_AUD, and the Access application actually protecting the selfhost custom domain isn't managed by this alchemy stack (it predates it / was set up by hand in the dashboard) — so it must be authorized there, by hand: Zero Trust > Access > Applications > (the app protecting the hostname) > Policies > add a "Service Auth" policy selecting this token. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.