Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,15 @@ All notable changes to Wallpect are recorded in this file. The format follows [K

## [Unreleased]

### Changed

- Moved `wallpect.k-y.cc` from a Worker route over the former Pages DNS record to a Workers Custom Domain.
- Updated deployment and rollback documentation for the Workers-only production architecture.

### Removed

- Removed the redundant Cloudflare Pages project, its public `pages.dev` deployment endpoint, and duplicate Git builds.

## [0.2.0] - 2026-07-19

### Added
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ Set `PLAYWRIGHT_BASE_URL` to run the same browser matrix against a deployed Work

## Deployment and releases

Wallpect is deployed as an assets-only Cloudflare Worker with Static Assets. A push to `main` triggers a production Workers Build; non-production branches create preview versions without changing production traffic. The previous Pages project is retained only as a documented rollback path.
Wallpect is deployed as an assets-only Cloudflare Worker with Static Assets. The Worker owns `wallpect.k-y.cc` as a Custom Domain. A push to `main` triggers a production Workers Build; non-production branches create preview versions without changing production traffic. Production rollback uses Workers version history; no Cloudflare Pages project is required.

See the [deployment guide](docs/DEPLOYMENT.md) for platform settings and the [release guide](docs/RELEASING.md) for the version, validation, preview, production, and rollback checklist.

Expand Down
2 changes: 1 addition & 1 deletion README.zh-Hant.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ npm run test:e2e

## 部署與版本發布

Wallpect 以不含 Worker script 的 Cloudflare Workers Static Assets 模式部署。推送至 `main` 會觸發正式 Workers Build;其他分支只會建立預覽版本,不會改變正式流量。原有 Pages 專案只保留作已記錄的回退路徑
Wallpect 以不含 Worker script 的 Cloudflare Workers Static Assets 模式部署,並由 Worker 以 Custom Domain 直接管理 `wallpect.k-y.cc`。推送至 `main` 會觸發正式 Workers Build;其他分支只會建立預覽版本,不會改變正式流量。正式回退使用 Workers 版本記錄,不再需要 Cloudflare Pages 專案

平台設定請參閱[部署指南](docs/DEPLOYMENT.md);版本、驗證、預覽、正式部署及回退程序請參閱[發布指南](docs/RELEASING.md)。

Expand Down
4 changes: 2 additions & 2 deletions TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
- [x] 加入預設繁體中文,並支援簡體中文與英文切換
- [x] 完成提交前的依賴、機密、瀏覽器介面與安全 header 審查
- [x] 以 Workers Builds 自動建立分支預覽,並從 `main` 部署 `wallpect.k-y.cc`
- [x] 保留原有 Cloudflare Pages 專案作回退路徑
- [x] 將正式網域改為 Workers Custom Domain,並移除多餘的 Cloudflare Pages 專案
- [x] 建立可重複的版本發布、正式驗證及 Workers 回退清單
- [ ] 完成實體裝置 Safari、低記憶體流動裝置、CMYK JPEG 與 EXIF 手動 QA

Expand All @@ -38,6 +38,6 @@
- [x] Default to Traditional Chinese and support Simplified Chinese and English switching
- [x] Complete pre-commit dependency, secret, browser-surface, and security-header review
- [x] Build branch previews automatically and deploy `main` to `wallpect.k-y.cc` with Workers Builds
- [x] Retain the existing Cloudflare Pages project as a rollback path
- [x] Move the production hostname to a Workers Custom Domain and remove the redundant Cloudflare Pages project
- [x] Document repeatable release, production verification, and Workers rollback procedures
- [ ] Complete physical-device Safari, low-memory mobile, CMYK JPEG, and EXIF manual QA
14 changes: 6 additions & 8 deletions docs/DEPLOYMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,11 @@ npm run worker:dev

建議對應:

- `main` → `wallpect.k-y.cc/*` Workers route
- `main` → `wallpect.k-y.cc` Workers Custom Domain
- 非 production branch → Workers Preview URL
- 可選的 `develop` branch → 獨立 preview 或 staging Worker

`wrangler.toml` 以 zone route 將 `wallpect.k-y.cc/*` 導向 Worker。現有 Pages custom domain 與 DNS 會保留作 origin 及 rollback;如要回復 Pages,可先在 Cloudflare dashboard 移除該 Worker route。確認 Workers 正式流量及 rollback 流程穩定之前,不要刪除原有 Pages project。

如日後要完全移除 Pages,可先解除 Pages custom domain 及其 CNAME,再將 route 改成 Workers Custom Domain。Custom Domain 不能與現有 CNAME 同時建立,因此唔應在同一次未驗證操作內完成。
`wrangler.toml` 以 `custom_domain = true` 將 `wallpect.k-y.cc` 直接綁定至 Worker。Cloudflare 會為 Custom Domain 管理相應 DNS 記錄及憑證;此專案不依賴外部 origin、Pages CNAME 或 Pages project。發生部署問題時,使用 Workers deployment history 或 `wrangler rollback` 回退,不要移除正式 Custom Domain。

Workers Builds 設定:

Expand All @@ -58,6 +56,7 @@ Cloudflare 會使用 `package.json` 鎖定的 Wrangler 版本;本機仍可使
- [Workers Builds 設定](https://developers.cloudflare.com/workers/ci-cd/builds/configuration/)
- [Build branch 控制](https://developers.cloudflare.com/workers/ci-cd/builds/build-branches/)
- [Static Assets SPA 導覽](https://developers.cloudflare.com/workers/static-assets/routing/single-page-application/)
- [Workers Custom Domains](https://developers.cloudflare.com/workers/configuration/routing/custom-domains/)
- [版本回退](https://developers.cloudflare.com/workers/versions-and-deployments/rollbacks/)

### 安全 header
Expand Down Expand Up @@ -126,13 +125,11 @@ npm run worker:dev

Suggested mappings:

- `main` → the `wallpect.k-y.cc/*` Workers route
- `main` → the `wallpect.k-y.cc` Workers Custom Domain
- non-production branches → Workers Preview URLs
- optional `develop` branch → a dedicated preview or staging Worker

`wrangler.toml` maps the `wallpect.k-y.cc/*` zone route to the Worker. The existing Pages custom domain and DNS remain in place as the origin and rollback path; to restore Pages, first remove this Worker route in the Cloudflare dashboard. Do not delete the Pages project until Workers production traffic and rollback have been confirmed stable.

To remove Pages completely later, detach its custom domain and CNAME before replacing the route with a Workers Custom Domain. A Custom Domain cannot be created while that CNAME exists, so these changes should not be combined into the initial, unverified cutover.
`wrangler.toml` binds `wallpect.k-y.cc` directly to the Worker with `custom_domain = true`. Cloudflare manages the corresponding DNS record and certificate for the Custom Domain; the project does not depend on an external origin, Pages CNAME, or Pages project. If a deployment is unhealthy, use Workers deployment history or `wrangler rollback` instead of removing the production Custom Domain.

Workers Builds settings:

Expand All @@ -149,6 +146,7 @@ Related official documentation:
- [Workers Builds configuration](https://developers.cloudflare.com/workers/ci-cd/builds/configuration/)
- [Build branch control](https://developers.cloudflare.com/workers/ci-cd/builds/build-branches/)
- [Static Assets SPA routing](https://developers.cloudflare.com/workers/static-assets/routing/single-page-application/)
- [Workers Custom Domains](https://developers.cloudflare.com/workers/configuration/routing/custom-domains/)
- [Version rollbacks](https://developers.cloudflare.com/workers/versions-and-deployments/rollbacks/)

### Security headers
Expand Down
4 changes: 2 additions & 2 deletions docs/RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ PLAYWRIGHT_BASE_URL=https://<preview-url> npm run test:e2e

若新版本有問題,優先以 Cloudflare Dashboard 的 Worker → Deployments 選擇上一個穩定版本,或使用 `wrangler rollback <version-id>`。回退會建立一個新的 deployment,並把所選版本設為 100% 正式流量。

若 Workers route 本身有問題,可在 Cloudflare Dashboard 移除 `wallpect.k-y.cc/*` Worker route,讓保留的 Pages custom domain 回復接收流量。完成事故記錄及修正前,不要刪除可用的舊 Worker version 或 Pages project
`wallpect.k-y.cc` 是 Worker 的 Custom Domain;回退時保留此網域綁定,只切換 deployment version。完成事故記錄及修正前,不要刪除可用的舊 Worker version。

## English

Expand Down Expand Up @@ -108,4 +108,4 @@ PLAYWRIGHT_BASE_URL=https://<preview-url> npm run test:e2e

If the release is unhealthy, select the previous stable version under Worker → Deployments in the Cloudflare dashboard, or run `wrangler rollback <version-id>`. A rollback creates a new deployment and sends 100% of production traffic to the selected version.

If the Worker route itself is unhealthy, remove the `wallpect.k-y.cc/*` Worker route in the Cloudflare dashboard so the retained Pages custom domain receives traffic again. Do not delete usable Worker versions or the Pages project until the incident is recorded and fixed.
`wallpect.k-y.cc` is the Worker's Custom Domain. Keep that domain binding in place during rollback and switch only the deployment version. Do not delete usable Worker versions until the incident is recorded and fixed.
4 changes: 2 additions & 2 deletions docs/WALLPECT_PRODUCT_REQUIREMENTS_AND_IMPLEMENTATION_PLAN.md
Original file line number Diff line number Diff line change
Expand Up @@ -1139,11 +1139,11 @@ Production branch: main
流量與預覽:

```text
main → wallpect.k-y.cc/* Workers route
main → wallpect.k-y.cc Workers Custom Domain
non-production branch → Workers version preview URL
```

原有 Pages project 只保留為回退路徑;日常正式部署、分支預覽及版本回退均以 Workers 為準。完整設定及驗證程序見 `docs/DEPLOYMENT.md` 與 `docs/RELEASING.md`。
`wallpect.k-y.cc` 由 Worker Custom Domain 直接管理;正式部署、分支預覽及版本回退均以 Workers 為準,不依賴 Pages project。完整設定及驗證程序見 `docs/DEPLOYMENT.md` 與 `docs/RELEASING.md`。

### 15.2 Headers

Expand Down
4 changes: 2 additions & 2 deletions wrangler.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ workers_dev = true
preview_urls = true

[[routes]]
pattern = "wallpect.k-y.cc/*"
zone_name = "k-y.cc"
pattern = "wallpect.k-y.cc"
custom_domain = true

[assets]
directory = "./dist"
Expand Down
Loading