From cb078d6b351d4586fc3a767346e9672d8dda4c91 Mon Sep 17 00:00:00 2001 From: onmax Date: Thu, 26 Mar 2026 13:08:57 +0100 Subject: [PATCH] chore: remove preview environments --- .github/workflows/ci.yml | 2 +- MIGRATION.md | 2 +- README.md | 8 +++----- app/app.vue | 27 ++++++++------------------- app/utils/environments.test.ts | 17 +++++++++++++++++ app/utils/environments.ts | 13 +++++++++++++ package.json | 2 +- wrangler.json | 24 ------------------------ 8 files changed, 44 insertions(+), 51 deletions(-) create mode 100644 app/utils/environments.test.ts create mode 100644 app/utils/environments.ts diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 68d8d94..0f6f8c7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,7 +12,7 @@ on: jobs: ci: runs-on: ubuntu-latest - environment: preview-testnet + environment: testnet steps: - uses: actions/checkout@v4 diff --git a/MIGRATION.md b/MIGRATION.md index d40600f..00546a9 100644 --- a/MIGRATION.md +++ b/MIGRATION.md @@ -59,4 +59,4 @@ curl -I https://validators-api-testnet.pages.dev/api/v1/status 1. Verify Workers fully operational 2. Deploy redirects to Pages projects 3. Monitor for 1-2 weeks -4. (Optional) Deprecate .pages.dev URLs and add custom domain +4. (Optional) Deprecate legacy `.pages.dev` URLs and add a custom domain diff --git a/README.md b/README.md index a62817d..57cf154 100644 --- a/README.md +++ b/README.md @@ -122,7 +122,7 @@ The Validators API provides endpoints to retrieve validator information for inte The Validators Dashboard is a simple Nuxt application that displays all validators along with their scores. You can access the dashboard here: https://validators-api-main.je-cf9.workers.dev/ > [!TIP] -> Check also the [deployment](#deployment) section to learn how to access to the `testnet` and `preview` environments. +> Check also the [deployment](#deployment) section to learn how to access the `testnet` environment. ## How the API works @@ -209,7 +209,7 @@ Deployed via Wrangler CLI with `wrangler.json` config: pnpm build && npx wrangler --cwd .output deploy [-e env] ``` -Where `env`: `preview`, `testnet`, or `testnet-preview` (omit for mainnet production). +Where `env`: `testnet` (omit `-e env` for mainnet production). **Required secrets:** `ALBATROSS_RPC_NODE_URL`, `NUXT_SLACK_WEBHOOK_URL` @@ -250,15 +250,13 @@ pnpm db:apply:is-listed:testnet **Environments** (configured in `wrangler.json`): - `production`: [Validators API Mainnet](https://validators-api-main.je-cf9.workers.dev) via manual `wrangler deploy` -- `preview`: [Validators API Mainnet Preview](https://validators-api-main.je-cf9.workers.dev) via manual deployment - `testnet`: [Validators API Testnet](https://validators-api-test.je-cf9.workers.dev) via manual `wrangler deploy --env testnet` -- `testnet-preview`: [Validators API Testnet Preview](https://validators-api-test.je-cf9.workers.dev) via manual deployment Each environment has its own D1 database, KV cache, and R2 blob. Sync runs every 12 hours via Cloudflare cron triggers (see `server/tasks/sync/`). ### Deployment Migration -Migrated from Cloudflare Pages to Workers for cron job support. +Migrated from Cloudflare Pages to Workers for cron job support. Pages URLs remain legacy redirects only and are not active deployment targets. **Old URLs (redirect to Workers):** diff --git a/app/app.vue b/app/app.vue index 24b2171..8916fee 100644 --- a/app/app.vue +++ b/app/app.vue @@ -1,4 +1,7 @@