-
Notifications
You must be signed in to change notification settings - Fork 1
48 lines (45 loc) · 1.08 KB
/
build-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
name: Build & Deploy
on:
workflow_dispatch:
push:
branches:
- master
jobs:
build:
name: Build Web App
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Dependencies
run: npm install
- name: Build
run: npm run build
- name: Archive Production Artifact
uses: actions/upload-artifact@v3
with:
name: production
path: dist
deploy:
needs: build
name: Deploy to seiKiMo
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'
steps:
- name: Download Artifact
uses: actions/download-artifact@v3
with:
name: production
path: dist
- name: ZIP Artifact
uses: vimtor/action-zip@v1
with:
files: dist/
dest: build.zip
- name: Deploy to seiKiMo
uses: KingRainbow44/upload-file@v1
with:
url: https://seikimo.moe/actions/site
file: build.zip
authorization: ${{ secrets.UPLOAD_TOKEN }}
method: POST