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
14 changes: 11 additions & 3 deletions .github/workflows/upload.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,15 @@ on:
permissions:
contents: read

concurrency:
group: upload-${{ github.repository }}-${{ github.event_name }}-${{ github.event.pull_request.number || github.ref }}
queue: max
cancel-in-progress: false

jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Check out repository
uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5.1.0
Expand All @@ -33,7 +39,7 @@ jobs:
- name: Set up Calcit and Caps
uses: calcit-lang/setup-calcit@ca701be5a471759e442aa053cd100720bbe1f09f # v1.5.0
with:
version: "0.27.0"
deps-file: deps.cirru
tools: calcit,caps
caps-version: "0.1.1"

Expand All @@ -58,9 +64,10 @@ jobs:
id: asset-path
env:
CDN_ORIGIN: https://cos-sh.tiye.me
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
if [[ "$GITHUB_EVENT_NAME" == "pull_request" ]]; then
asset_prefix="${GITHUB_REPOSITORY}/pr/"
asset_prefix="${GITHUB_REPOSITORY}/pr/${PR_NUMBER}/${GITHUB_RUN_ID}/${GITHUB_RUN_ATTEMPT}/"
else
asset_prefix="${GITHUB_REPOSITORY}/"
fi
Expand Down Expand Up @@ -101,7 +108,8 @@ jobs:

- name: Upload and verify frontend assets on COS
if: steps.cos-credentials.outputs.available == 'true'
uses: worktools/cos-upload-action@17e6d213fe9f6772a6090a13c8ba044cd6cbcb09 # v1.1.1
uses: worktools/cos-upload-action@v1.2.0
timeout-minutes: 10
with:
source-dir: dist
bucket: ${{ secrets.COS_BUCKET }}
Expand Down
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,15 @@ http://repo.topix.im/tabletwo/
The existing web entry and the separate `/servers/tabletwo/` rsync deployment
remain in place. COS migration applies only to the frontend `dist/` assets:
GitHub Actions builds them against `https://cos-sh.tiye.me/TopixIM/tabletwo/`
(`.../pr/` on pull requests), uploads them, and verifies their public URLs.
(`.../pr/<number>/<run>/<attempt>/` on pull requests), uploads them, and verifies their public URLs.

前端使用 COS Action v1.2.0 的 `public-base-url` 内置校验,不添加重复验证脚本。
PR 资源隔离到独立运行目录,上传按事件及分支排队;job/上传分别限制为 15/10 分钟。
保留现有 Yarn 4.12.0 锁文件;Calcit 从 deps.cirru 读取版本,现有 client/server 门禁保留。
本轮保留 Calcit/procs 0.27.0,不代表已完成 0.28 类型迁移。生产 CDN 前缀与
`/servers/tabletwo/` 服务端部署路径不变。
移除误跟踪的过时 `dist-server/package.json`;它仍由原构建步骤从根 manifest 生成,
不会改变服务端打包或部署内容。`dist-server/` 原本已被 gitignore 忽略。

> We need a table for two people. They sit in front of each other, seeing into the eyes, and to compose the same markdown file togather.

Expand Down
28 changes: 0 additions & 28 deletions dist-server/package.json

This file was deleted.

Loading