-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (50 loc) · 1.39 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
on: push
name: 🚀 Build & Deploy
jobs:
web-deploy:
name: Build & Deploy
runs-on: ubuntu-latest
steps:
- name: Get latest code
uses: actions/checkout@v3
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.2
- name: Validate composer.json and composer.lock
run: composer validate --strict
- name: Cache Composer packages
id: composer-cache
uses: actions/cache@v3
with:
path: vendor
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-php-
- name: Install Composer dependencies
run: composer install --prefer-dist --no-progress
- name: Setup Node / NPM
uses: actions/setup-node@v3
with:
node-version: '18.x'
- name: Cache NPM packages
id: npm-cache
uses: actions/cache@v3
with:
path: node_modules
key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-npm-
- name: NPM install
run: npm install
- name: NPM build
run: npm run build
- name: Deploy files
uses: SamKirkland/FTP-Deploy-Action@v4.3.4
with:
server: 149.210.213.94
username: pool@joeke.dev
password: ${{ secrets.ftp_password }}
exclude: |
**/.git*
**/.git*/**