-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (36 loc) · 1.11 KB
/
deploy.yml
File metadata and controls
40 lines (36 loc) · 1.11 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
name: Deploy
on:
push:
branches: [ master ]
workflow_dispatch: # Allows you to run this workflow manually from the Actions tab
jobs:
build_and_deploy_blog:
name: Build and Deploy Blog
runs-on: ubuntu-latest
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
- run: yarn install --frozen-lockfile
- name: Build
env:
GOOGLE_ADSENSE_CLIENT_ID: ${{ secrets.GOOGLE_ADSENSE_CLIENT_ID }}
GOOGLE_ANALYTICS_ID: ${{ secrets.GOOGLE_ANALYTICS_ID }}
ALGOLIA_APP_ID: ${{ secrets.ALGOLIA_APP_ID }}
ALGOLIA_API_KEY: ${{ secrets.ALGOLIA_API_KEY }}
ALGOLIA_INDEX_NAME: ${{ secrets.ALGOLIA_INDEX_NAME }}
run: yarn build
- uses: actions/configure-pages@v3
- uses: actions/upload-pages-artifact@v1
with:
path: .vitepress/dist
- name: Deploy
id: deployment
uses: actions/deploy-pages@v2