-
-
Notifications
You must be signed in to change notification settings - Fork 0
60 lines (52 loc) · 1.46 KB
/
deploy.yml
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
54
55
56
57
58
59
60
name: Deploy & Publish
on:
release:
types: [ published ]
jobs:
# Prepare and publish
deploy:
name: Deploy to Workers
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
# Check out current repository
- name: Fetch Sources
uses: actions/[email protected]
with:
ref: ${{ github.event.release.tag_name }}
- name: Install pnpm package manager
uses: pnpm/[email protected]
with:
version: latest
# Cache dependencies to speed up builds
- name: Cache cargo dependencies
uses: actions/[email protected]
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Install stable toolchain
uses: actions-rs/[email protected]
with:
toolchain: stable
target: wasm32-unknown-unknown
override: true
- name: Deploy to Workers
uses: cloudflare/[email protected]
with:
accountId: ${{ secrets.CF_ACCOUNT_ID }}
apiToken: ${{ secrets.CF_API_TOKEN }}
command: deploy
secrets: |
GA_ID
env:
GA_ID: ${{ secrets.GA_ID }}
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true