-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (58 loc) · 1.86 KB
/
main.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Build, Test and Deploy with FTP
on: push
jobs:
eslint-check:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v1
with:
fetch-depth: 1
- uses: pnpm/action-setup@v2
with:
version: 8.6.11
- name: pnpm install
run: pnpm install --frozen-lockfile
- name: Run ESLint
run: pnpm run eslint:scan
nuxt-generate:
name: Yarn build
runs-on: ubuntu-20.04
needs:
- eslint-check
steps:
- uses: actions/checkout@v2
- uses: pnpm/action-setup@v2
with:
version: 8.6.11
- uses: actions/setup-node@master
with:
node-version: 18
- name: pnpm module install
run: pnpm install --frozen-lockfile
- name: nuxt generate
run: pnpm run generate
- uses: actions/upload-artifact@master
with:
name: build-artifact
path: .output/public/
# Deploy if this is the master branch
deploy:
needs:
- nuxt-generate
runs-on: ubuntu-20.04
if: github.ref == 'refs/heads/master'
name: Deploy to FTP Server
steps:
- uses: actions/download-artifact@master
with:
name: build-artifact
path: .output/public/
- name: Deploy to FTP Server
uses: SamKirkland/[email protected]
with:
server: ha01s018.org-dns.com
username: bassadin_root_website
password: ${{ secrets.FTP_Password }}
protocol: ftps
local-dir: .output/public/
security: strict