-
Notifications
You must be signed in to change notification settings - Fork 0
68 lines (55 loc) · 1.53 KB
/
release.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
57
58
59
60
61
62
63
64
65
66
67
68
name: Build Blog
on:
push:
paths:
- src/**
- public/**
- functions/**
- "*.mjs"
- "*.json"
workflow_call:
secrets:
CLOUDFLARE_ACCOUNT_ID:
required: true
CLOUDFLARE_API_TOKEN:
required: true
workflow_dispatch:
jobs:
release:
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-release
steps:
- uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '18'
cache: 'yarn'
- name: install package
run: yarn
- name: build site
run: yarn build
- name: Publish to Cloudflare Pages
uses: cloudflare/pages-action@1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: blog
directory: dist
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref_name }}
# - run: sleep 60
# - name: Send webmentions
# run: node pipeline/send-mentions.js
# - name: Run scraper
# env:
# HOST_URL: ${{ secrets.MEILISEARCH_HOST_URL }}
# API_KEY: ${{ secrets.MEILISEARCH_API_KEY }}
# CONFIG_FILE_PATH: meili.json
# run: |
# docker run -t --rm \
# -e MEILISEARCH_HOST_URL=$HOST_URL \
# -e MEILISEARCH_API_KEY=$API_KEY \
# -v $PWD:/blog \
# getmeili/docs-scraper:latest pipenv run ./docs_scraper /blog/meili.json