-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (39 loc) · 1.12 KB
/
Copy pathci.yml
File metadata and controls
46 lines (39 loc) · 1.12 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
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- run: npm ci
- name: Unit tests
run: npm run test
# Dummy values satisfy $env/static/private at build time.
# Real secrets are never required to build — if this fails,
# a server-only module has leaked into the client bundle.
- name: Build
run: npm run build
env:
DATABASE_URL: postgresql://ci:ci@localhost/ci
AUTH_SECRET: ci-secret
GITHUB_CLIENT_ID: ci-id
GITHUB_CLIENT_SECRET: ci-secret
ALLOWED_GITHUB_USERNAME: ci-user
AUTH_TRUST_HOST: "true"
- name: Type check
run: npm run check
env:
DATABASE_URL: postgresql://ci:ci@localhost/ci
AUTH_SECRET: ci-secret
GITHUB_CLIENT_ID: ci-id
GITHUB_CLIENT_SECRET: ci-secret
ALLOWED_GITHUB_USERNAME: ci-user
AUTH_TRUST_HOST: "true"