Repository navigation
53 lines (48 loc) · 1.69 KB
/
Copy pathworker.yml
File metadata and controls
53 lines (48 loc) · 1.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# The Worker of apps/api (domains-pkgforge-dev on domains.pkgforge.dev, DOM-030;
# docs/worker.md), in the shape of mirror-archlinux's .github/workflows/worker.yml
# at commit 669ac725f8081445c164113f2ed092533de112e2.
#
# test node scripts/test.mjs apps/api, on the Node of .node-version
#
# The tests run the Worker in workerd (packages/testkit), which needs the locked
# dependencies and a glibc runner, so the job installs them with the pinned
# setup-node of ci.yml rather than in the mirror's node:24-alpine image.
#
# CI does not deploy, and holds no Cloudflare credential (AGENTS.md absolute
# 14). The operator's wrangler login deploys, after this passes:
# cd apps/api && npx wrangler@4.156.1 deploy --var BUILD:$(git rev-parse --short=12 HEAD)
name: Worker
on:
push:
branches: [main]
paths:
- 'apps/api/**'
- '.github/workflows/worker.yml'
workflow_dispatch:
permissions: {}
concurrency:
group: worker-${{ github.ref }}
cancel-in-progress: false
defaults:
run:
shell: bash
jobs:
test:
runs-on: ubuntu-24.04
timeout-minutes: 15
permissions:
contents: read
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
# package.json names npm in packageManager, which turns setup-node's
# cache on by default. It is off, as in ci.yml.
- uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7.1.0
with:
node-version-file: .node-version
package-manager-cache: false
- name: Install the locked dependencies
run: npm ci
- name: The Worker's tests
run: node scripts/test.mjs apps/api