All checks were successful
Build and Deploy / build_and_deploy (push) Successful in 1m16s
35 lines
956 B
YAML
35 lines
956 B
YAML
name: Build and Deploy
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
build_and_deploy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Install prerequisites
|
|
run: apt update -y && apt install -y make php git curl composer
|
|
- name: Checkout Repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
submodules: recursive
|
|
- name: Compile Web Pages
|
|
run: |
|
|
composer install
|
|
mkdir -p ./out
|
|
cp -r ./www ./out
|
|
cp -r ./vendor ./out
|
|
- name: SFTP Deploy
|
|
uses: wlixcc/SFTP-Deploy-Action@v1.2.5
|
|
with:
|
|
username: '${{ vars.SSH_USER }}'
|
|
server: '${{ vars.SSH_SERVER }}'
|
|
port: '${{ vars.SSH_PORT }}'
|
|
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}
|
|
local_path: './out/*'
|
|
remote_path: '${{ vars.DESTINATION }}'
|
|
sftpArgs: -o ConnectTimeout=10
|
|
rsyncArgs: --exclude=.*
|