-
Notifications
You must be signed in to change notification settings - Fork 25
56 lines (51 loc) · 1.75 KB
/
w3console.yaml
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
name: w3console
on:
workflow_dispatch:
push:
branches:
- main
paths:
- 'examples/react/w3console/**'
pull_request:
branches:
- main
paths:
- 'examples/react/w3console/**'
jobs:
publish:
name: Publish
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/pnpm
- name: Build w3console
run: pnpm build
working-directory: examples/react/w3console
env:
VITE_W3UP_ACCESS_SERVICE_URL: 'https://staging.up.web3.storage'
VITE_W3UP_ACCESS_SERVICE_DID: 'did:web:staging.web3.storage'
VITE_W3UP_UPLOAD_SERVICE_URL: 'https://staging.up.web3.storage'
VITE_W3UP_UPLOAD_SERVICE_DID: 'did:web:staging.web3.storage'
VITE_W3UP_SERVICE_BRAND_NAME: 'preview.web3.storage'
- name: Publish static site
uses: ./.github/actions/preview
id: preview
with:
path_to_add: examples/react/w3console/dist
web3_token: ${{ secrets.WEB3_TOKEN }}
# Enable to publish dnslink on merge to main
# dnslink_record: console
# dnslink_domain: web3.storage
cf_pages_project: console-web3-storage-preview
cf_account_id: ${{ secrets.CF_ACCOUNT_ID }}
cf_token: ${{ secrets.CF_TOKEN }}
- name: Add Preview URLs as Job Summary
run: echo "${{ steps.preview.outputs.summary }}" >> $GITHUB_STEP_SUMMARY
- name: Find Current Pull Request
uses: jwalton/[email protected]
id: finder
- name: Update Preview URLs PR Comment
uses: marocchino/[email protected]
with:
number: ${{ steps.finder.outputs.pr }}
message: ${{ steps.preview.outputs.summary }}