-
Notifications
You must be signed in to change notification settings - Fork 1
55 lines (50 loc) · 1.46 KB
/
deploy.yaml
File metadata and controls
55 lines (50 loc) · 1.46 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
47
48
49
50
51
52
53
54
55
name: Deploy to GitHub Pages
on:
deployment:
jobs:
deploy:
name: Deploy to GitHub Pages
runs-on: ubuntu-latest
steps:
-
name: Update the status in_progress
uses: chrnorm/deployment-status@releases/v1
with:
deployment_id: ${{ github.event.deployment.id }}
description: Start to deploy.
state: in_progress
token: "${{ github.token }}"
-
uses: actions/checkout@v2
-
uses: actions/setup-node@v2
with:
node-version: 14.17.6
- name: Build website
run: |
npm install --frozen-lockfile
npm run build
- name: Publish to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.DEPLOY_TOKEN }}
publish_dir: ./build
cname: www.gitploy.io
-
name: Deploy successfully
if: success()
uses: chrnorm/deployment-status@releases/v1
with:
deployment_id: ${{ github.event.deployment.id }}
description: Finish to deploy successfully.
state: "success"
token: "${{ github.token }}"
-
name: Deploy failed
if: failure() || cancelled()
uses: chrnorm/deployment-status@releases/v1
with:
deployment_id: ${{ github.event.deployment.id }}
description: Failed to deploy.
state: "failure"
token: "${{ github.token }}"